leonardo is a CLI tool that aides in developing components for DS bundles.
yarn add -D @orchatect/leonardo
leonardo is a tool that makes developing DS bundles easier and less opinionated. It is a transpiler, a bundler, and a provider of cleaner and simpler API wrappers around APIs provided by DS.
Given this setup:
You get this output:
A component's source directory can be named whatever you like. You have the freedom to choose camel casing or snake casing the name.
/source/components/my_comp, it is your choice.
Inside of your component's source directory, there are only four requirements in order for
leonardo to work properly.
.dsconfig.jsonfile. This JSON data is only slightly different than the data you would find in the various configuration elements within a standard DS
Client.htmlfile. The main differences, other than the filetype, are as follows:
className, you will use the sensible and intuitive alternative:
serverName. The value of
serverNameapplies exactly how you would expect it to: It becomes the name of your component's server.
yarn scripts build