Closed leonid-bauxy closed 7 years ago
Could you provide more of your config please?
Ah, yeah, looks like this needs to be updated to support objects. And we should probably add some tests for that here.
Feel free to makeapullrequest.com :smile:
@kentcdodds sure, it's pretty big, though. Let me know what relevant parts you'd like me to extract.
webpack.config.babel.js
: https://gist.github.com/leonid-bauxy/d94f54e41d67c8346caaaed3046cd9c6
./helpers/getStylesLoaders.js
: https://gist.github.com/leonid-bauxy/22d70a5257e850bc1ecd68e390b62de0
./helpers/getBabelConfig.js
: https://gist.github.com/leonid-bauxy/48d132157906708cc8666f8ec563a535
The utility ./helpers/hoistLoaderIfOne
, that i've made just to make the validator happy. But it still covered only some of the cases): https://gist.github.com/leonid-bauxy/5e829251335f521c42547bff4d574064
Validation Result: https://gist.github.com/leonid-bauxy/de9c143c91fbd924ce136d3985244711
Edit: I re-posted this comment after removing some(probably) confidential info.
@kentcdodds thanks for the tips! Will make a PR soon.
It's still a valid if it's in a form of object and
webpack
needs to parse it after anyway. Don't you think users should be allowed to use the form they prefer if bothstring
andobject
forms are valid. Or at least add an option to disable this check? Would you accept a pull-request?In this case I receive an error, even though it's valid: