investigate a possibility to render css module names statically instead of dynamically, since we have a name map during the processing https://twitter.com/Linus_Borg/status/1310844386536718339 vuejs/core#2417
check to specifying <style>
in the beginning of the file before <template>
@todo $cssModule('name')
script macro to statically replace names in resulting code and completely dropping embedding of css modules code chunk
this is ...
- cool thing
babel traverse doesn't process the root node, so visitors won't be called on that.
solution is to wrap ast into ExpressionStatement but it then generates the result with a semicolon as if using parse
insted of parseExpression
ended up just using parse and .slice(0, -1)
to remove the semicolon
options:
{
linkingPrefix: '-',
linkingDir: '_',
linkingSeparator: '--'
}
// link from /src/
.-components_menu_button--wrap
- link .wrap
class from `/src/components/menu/Button.vue
you will have to pass original source code too and work with it instead