Blueprints and exporters are a very powerful technology allowing you to define, manipulate, and generate nearly any textual output. However, the primary reason for technology like this is the code generation, converting designs and design data into production-ready code.
Supernova gives you the ability to tap into a vast pool of information about every processed design, down to the last atomic element, down to the last code property - and you access all of it through the Universal Data Model (UDM).
This is how Universal Data Model works and communicates with the rest of the Studio:
The data model is one unified description of the design and all additional data available in Supernova (including computed data). The data model is created in the following way:
Design from a design tool is processed and converted into an intermediate form
The intermediate form is refined - optimizations are run on top of the raw data to understand the purpose behind each design element, and to clean it from any design data that have no informational value. This can be hidden layers, extraneous groups, wrong labels and so on
The intermediate form is converted into stable Universal Data Model
Once the design was converted into the stable UDM, it is ready to be used in the exporters. Exporters can access all data obtained from this import chain, such as project screens, screen components, animations, localizations, and much, much more.
Universal Data Model shields you from the differences coming from the design editors. For example, Sketch and Figma data models are vastly different, with different concepts and different usage patterns. Supernova unifies those models into one that is much closer to what you expect in the development world.
In terms of exporters, Universal Data Model describes exactly one, currently opened project. This means that you can run the exporter and produce a certain output, then open another save file, and produce a completely different output - using the same exporter. There are 2 main sources of data available:
Stored data, which are either provided by the user or as the initial information obtained by importing the design file. This is everything from screens to components to animations to navigation connections and any other piece of information you'll find in the editor interface
Computed data, which are created on the fly when requested. Exporters and blueprints have the entire Supernova computing engine available, so you can request to compute a valid flexbox layout, compute unique names, get dynamic assets and so on
You access UDM and all stored procedures using functions. All functions can be invoked from every blueprint, without limitations.
This documentation provides a description of all objects and all functions you can use within blueprints. Select which one you are interested in to explore more.