Closed wallzero closed 4 years ago
However, there has been confusion whether downstream library users must install babel-plugin-react-css-modules. For example, some projects may not be using babel, so users don't understand why they require a babel plugin along with its dependencies.
Downstream projects do not need to use Babel, but you have to have babel-plugin-react-css-modules
as a dependency (not devDependency
).
Thanks I get that. I just think it'd be easier if the runtime was a separate package.
I am using
babel-plugin-react-css-modules
in a couple libraries I work on (ui-router-react-digest
,react-ag
). Withbabel
andwebpack
, I am able to bundle these libraries into a single.js
and.css
- and withbabel-plugin-react-css-modules
, my CSS class names are locally scoped.However, there has been confusion whether downstream library users must install
babel-plugin-react-css-modules
. For example, some projects may not be usingbabel
, so users don't understand why they require ababel
plugin along with its dependencies.I'm curious if it is possible separate the runtime component into another package - perhaps something like
react-css-modules-runtime
? That would be easier to pass as a downstream dependency.Thanks!