The origins of Grav come from a personal desire to work with an open source platform that focused on speed and simplicity, rather than an abundance of built-in features that come at the expense of complexity.
All of these platforms rely on a database for data persistence, are powerful, and offer a good degree of flexibility.
One real downside to these platforms is they require a real commitment to learn how to use and develop on them. You really have to pick one out of the pack, and dedicate yourself to that platform if you wish to become competent as either a user, developer, or administrator.
What if there was a platform that was fast, easy-to-learn, and still powerful & flexible? Surely something already exists that meets these criteria? In my search for such a platform, it became clear that a flat-file based CMS was likely to be the answer, and there are a bunch to choose from! I created a list of requirements I thought would ensure an ideal platform for my needs:
- Fast, right out of the box
- Flat-file based
- Content created in Markdown
- Templating provided by Twig or a similar established project
- Extensible and flexible via far-reaching plugin architecture
- Simple to install, with minimal server requirements
- Must be open source and MIT licensed if possible
- Solid Documentation
- Enjoyable to use
The problem was, nothing really fit my requirements exactly. The ones that met my requirements the closest were not open source, so the option of forking it and adding the features I wanted was not available. I was left with two options:
- Start with one of the open source platforms and transform it into my ideal solution.
- Start from scratch
Originally, I thought that Pico might make a good base to start from as it already satisfied a good deal of the requirements. However, as I delved deeper, I realized it was not going to make a great starting point due to its functional approach. So, option #2 was the only option left to me. I started over.
Grav is heavily inspired by a whole raft of other platforms, but is written from scratch focusing on speed, simplicity, and flexibility.
The core of Grav is built around the concept of folders and markdown files for content. These folders and files are automatically compiled into HTML and cached for performance.
Its pages are accessible via URLs that directly relate to the folder structure that underpins the whole CMS. By rendering the pages with Twig Templates, you have complete control over how your site looks, with virtually no limitations.
Part of the flexibility comes from Grav's simple, but powerful, taxonomy functionality that lets you create relationships between pages. Another key part of this flexibility is the plugin architecture that exists throughout the entire platform to allow you to interact and modify pretty much any part of Grav as needed.
The base Grav package comes with two plugins, the first one is the
Error plugin and it's required to handle 404s and other HTTP error codes. The other one is called
Problems and it's entirely optional, but helps identify any potential setup or installation issues.
We have already developed a collection of assorted plugins including:
TaxonomyList and others. None of these are required for Grav to function, but they offer additional functionality if needed. By using plugins to extend Grav's functionality, it allows the core of Grav to remain focused, uncluttered, and speedy! Also it means we can rapidly release new plugins and add to the list of capabilities without another Grav release.
We have now launched the http://getgrav.org site and alongside it, the http://learn.getgrav.org documentation site. The documentation site is not complete, and we will continue to add to it over the coming months. Of course, both of these sites are built 100% with Grav.