optimize your development
Since Sitecore’s inception, the only real options available to you when it came to effectively synchronizing your models with Sitecore templates were quite limited. You could either choose to rely on Team Development for Sitecore (TDS) to automatically build the models for you, or, alternatively, you could opt to hand-code them manually.
With the introduction of Sitecore Serialization and the subsequent emergence of Sitecore headless and JavaScript Services (JSS), the options available to developers has dropped to zero! That is, until now…
The Development X-ccelerator
The Model Generator is a set of tools built with an array of configurations and options to greatly streamline the process of mapping Sitecore templates to your code. It is also built with extensibility in mind; that enables the developer to create models that work for your application.
It generates a single model file that represents a single Sitecore template. These models can be produced in any desired format, such as GlassMapper, SXA, React, VueJs models, etc. If it is not available out-of-the-box, it is straightforwards to develop what you require and integrate it.
You can also configure the tool to read from Sitecore serialized files (YML), Unicorn (YML), TDS (Item or YML) or directly from Sitecore using GraphQL. Again, if you need something different it can be easily built and integrated in.
The tool comes in two distinct parts:
A console application, that can be run without the need to be connected to Sitecore, either as a stand-alone application, as part of a build process or as a Visual Studio task runner task.
A Sitecore Module, that gives a developer even more flexibility, including the ability to create different kinds of models or even add related files such as controllers and rendering models! All of which can be viewed, managed, and downloaded from within Sitecore. One of the biggest benefits of the module is that the models are automatically added, deleted, and updated to reflect any changes to their corresponding templates in Sitecore.
In the traditional Sitecore set up, most of us have used Team Development for Sitecore (TDS) to do model generation, but now with the advent of Sitecore Serialization (or if you are using Unicorn), there is very little out there that can do this for you. So you end up creating these models by hand, which inevitably leads to issues, especially when templates change in Sitecore and are not regenerated.
“TDS has been the tool of choice for most projects I have been on, but it becomes a real pain to use when you have a lot of templates.”
TDS has a number of issues, which this tool tries to overcome, these include:
The model file can become massive and as a result difficult to read and manage (I.e., merge)
The model file contains lots of models that will never be used, which all get loaded into memory at startup
The models do not inherently respect the Sitecore Helix architecture
The model generation is inflexible and hard to configure
When working with large TDS projects the model files are known to get corrupted or fail to output the correct results
The model files sometimes get regenerated when the project is loading up
This tool has been developed in the field, used in multiple builds, making sure that it can work in a variety of projects and situations.
Why not reach out today and see if this tool can improve your productivity!
“Since we’re now using Next.js and React, this is the only tool capable of building our models!”
But there’s More…
We are pleased to announce an exciting enhancement to the Development X-ccelerator. Our tool now supports Contentstack. This enhancement allows users to extract Content Type and Global Type schema directly from Contentstack and convert these into models.
Stay tuned for additional updates including videos, tutorials, and further developments. We are committed to continually improving our offerings and enhancing the tools.