v0.5.12
Features
Now you can define Dynamic Components.
With this feature, you can create components, that changes style based on matches from regular expression
For example:
title--large title--$red
const compilerConfig = {
components: {
// title--$red
// title--#06f
'title(?:--(\\S+))?': ({ matches, variables, helpers, dev }) => {
const color = matches[1] ?? '#000';
return `font-size:24px${color ? ` color:${color}` : ''}`;
},
}
}; What's Changed
Full Changelog: v0.5.11...v0.5.12