babel-plugin-wrap-in-js
babel-plugin-wrap-in-js copied to clipboard
babelrc should be set to false for css files
I had a some problems adding react-dates to a project that seem to stem from wrap-in-js. @ljharb seems to think that they can be solved by telling this plugin to ignore the .babelrc that it finds inside the modules being imported.
I'm having a little trouble figuring out how to configure that inside a plugin. Everything I can find seems to be about setting it when you initiate a transformation. Should this plugin mutate the babel that gets passed to it here? That seems a little strange
The work around I did was to take the css file that I'm trying to import outside of node_modules and to put it in my styles directory, so that it's far away from it's .babelrc, but this isn't a very nice solution
I installed below packages to fix this issue.
npm install --save-dev babel-plugin-inline-react-svg npm i babel-plugin-transform-replace-object-assign npm i babel-preset-airbnb --save-dev