Developer
This section focuses on how to build content rich applications backed by CrafterCMS. It covers the basic topics you need to define a content type and render that content as part of a page, component or service. It also covers topics like building queries, accessing services and extending the core platforms and the developer workflow (DevContentOps).
Developers need to be comfortable with Content Modeling (how to represent content in CrafterCMS for your application to retrieve said content), and how to access content items from your application/project.
Note
For local development, you’ll need to install CrafterCMS locally and that’s best done via the local bundle. Instructions on how to do that are in Binary Bundles. Other options include running CrafterCMS in Docker or installing CrafterCMS from source.
CrafterCMS supports both headless and templated projects (templated projects are the traditional web sites with a view layer).
Regardless of type of project, a developer needs to be familiar with the following core concepts.
Core Concepts
Topic |
Description |
---|---|
Provides you information on giving structure and organization to your content |
|
Shows you the CrafterCMS repository structure |
|
Allows you to augment or override existing content using inheritance |
|
Provides you information on how to access your content via APIs |
|
Provides you information on how to access static contents such as images, CSS files, etc. |
|
Provides information on the UI layer on top of your applications that enables authors with in-context editing (ICE) |
|
Provides you information on how to use Groovy to develop server-side services and applications |
|
Provides you information on security features that can be used to secure your project/site |
|
Provides you information on how to perform content queries |
Additional Concepts
Aside from the core concepts listed above, a developer needs to be familiar with the following additional general concepts.
Topic |
Description |
---|---|
Provides you information on scheduling jobs |
|
Provides you information on page and component controllers |
|
Provides you information on rendering content adapted to different things |
|
Provides you information on creating and configuring a filter |
|
Provides you information on performing date operations in Groovy |
|
Provides you information on performing redirects (send users from one URL to another URL) |
|
Provides you information on working with Sass in CrafterCMS |
|
Provides you information on multi-environment support |
|
Provides you information on creating custom error pages |
|
Provides you information on adding a new language to Studio |
|
Provides you information on localizing content |
|
Provides you information on accessing custom environment variables |
Headless
CrafterCMS is natively headless. CrafterCMS simply retrieves content that the developer models in the modeling tool, applies actions/rules like inheritance, security, versioning, etc. and returns the transformed content to the caller as JSON. Developers can use whatever front-end technology they want including, but not limited to: React, Vue, Angular, Flutter or similar SPAs, Android and iOS applications, etc.
Headless Examples
Templated
CrafterCMS embeds FreeMarker to provide a high-performance, clean, flexible, and tolerant of syntax variance, templating engine to render HTML directly from CrafterCMS.
It allows developers to model the content as general reusable items, and fold those into pages. Pages aggregate content from components as needed and are associated with a FreeMarker template that can render the final page. The choice of HTML tools and frameworks doesn’t matter to CrafterCMS.
The article, Templating, provides more details on CrafterCMS provided tools for creating your templated project.
Templated Examples
Composable
CrafterCMS is a composable CMS and provides a modular and flexible approach to building and managing websites and digital experiences. Unlike traditional monolithic CMSs, which come with pre-built features and a fixed structure, CrafterCMS allows users to assemble and configure their own system by choosing and integrating individual components or services.
The article, Composable, provides more details on the composable nature of CrafterCMS and how to take advantage of it.
DevContentOps
DevContentOps is a set of tools and processes that allow teams of software developers, content authors, and system administrators to work together on a single project across multiple environments. These tools and processes are fully described in DevContentOps.
Studio is a great tool for content authors and for quick changes, but for development, you’ll want to use your IDE. Learn how to use your IDE with Studio in the Working in Your IDE article.
Upgrade
Upgrading CrafterCMS from a developer’s perspective is covered in Upgrade.
Managing Secrets
Credentials may be required in some cases when accessing content. For more information on how to manage/encode your secrets such as AWS credentials, please see Managing Secrets.
Logging
While developing your project, there are times when you’d like to see more log details, to figure out what is happening and address it as needed. Overriding the logging levels allows you to see more or less details depending on your needs.
Please review the Logging article for more information.
More Resources
Below is a short set of links to other documentation for technology that CrafterCMS leverages:
Attribute Name |
Usage |
Links |
---|---|---|
Spring Beans
Spring MVC
|
Server App Framework
|
|
Freemarker
|
Server side templates
|
|
Groovy
|
Server side scripting
|
|
OpenSearch
|
Search and content query
|
|
MongoDB
|
Crafter Profile and Social
data store
|
|
GIT
|
Repository Implementation
|
|
RST
|
Documentation source format
|
Note
CrafterCMS is a Git-based CMS. Please note that your system’s global git ignore file (list of rules for ignoring files in every Git repository on your computer) is respected by CrafterCMS. In case you find some of your content not being committed into CrafterCMS, check your global git ignore file to verify the content you’re committing is not being ignored.