stylelint: Error: only one instance of babel-polyfill is allowed
After upgrade stylelint to version 6.4.x my project throw error when buid.
Error:
Error: only one instance of babel-polyfill is allowed
at Object.<anonymous> (/home/.../node_modules/stylelint/node_modules/babel-polyfill/lib/index.js:12:9)
...
My project use stylelint via stylelint-webpack-plugin with webpack@1.x and babel@5.x
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Comments: 30 (25 by maintainers)
Commits related to this issue
- Temporarily lock stylelint version to avoid Travis errors More info: https://github.com/stylelint/stylelint/issues/1316 — committed to stylelint-scss/stylelint-scss by deleted user 8 years ago
- Remove babel-polyfill and spread usage; fixes #1316 — committed to stylelint/stylelint by davidtheclark 8 years ago
I think babel-polyfill is the culprit. It should be able, like all polyfill to detect and adjust the definition. This behavior (from a user point of view) is just stupid.
@vn38minhtran did you try this? If so why this simple hook is not included in the polyfill itself?!
@evilebottnawi I use node v4 and I think issue can be solved if we safely require babel-polyfill
No rush from my side, I am going to bed and won’t cut a release until tomorrow 😃 Thanks for you hard work!