What problem does this feature solve?
The localsConvention option of CSS modules allows to configure how the fields in the style object will be named. It's also configurable via Vite/Nuxt, but @vue/language-core ignores it and always generates the field name equal to the class name.
What does the proposed solution look like?
Add new option cssModulesLocalsConvention in vueCompilerOptions in tsconfig.json to configure it. Since we cannot access Vite or Nuxt configs, I think vueCompilerOptions is the best place and there is already strictCssModules.
What problem does this feature solve?
The
localsConventionoption of CSS modules allows to configure how the fields in the style object will be named. It's also configurable via Vite/Nuxt, but @vue/language-core ignores it and always generates the field name equal to the class name.What does the proposed solution look like?
Add new option
cssModulesLocalsConventioninvueCompilerOptionsintsconfig.jsonto configure it. Since we cannot access Vite or Nuxt configs, I thinkvueCompilerOptionsis the best place and there is alreadystrictCssModules.