You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Which Stylelint-related dependencies are you using?
"stylelint": "^15.10.3",
What did you expect to happen?
Lint won't return a runtime error.
What actually happened?
Error [ERR_REQUIRE_ESM]: require() of ES Module /Users/user1/Projects/project1/node_modules/string-width/index.js from /Users/user1/Projects/project1/node_modules/stylelint/lib/formatters/stringFormatter.js not supported.
Instead change the require of index.js in /Users/user1/Projects/project1/node_modules/stylelint/lib/formatters/stringFormatter.js to a dynamic import() which is available in all CommonJS modules.
Do you have a proposal to fix the bug?
Upgrade string-width to its latest version.
Currently used by stylelint:
Latest version available:
The text was updated successfully, but these errors were encountered:
@arantebw Thanks for opening the issue using the template. I'm afraid that Stylelint v15 doesn't support ESM yet, so stylelint@15.10.3 needs to use older versions of string-width. See also the dependencies restriction below:
$ npm v stylelint@15.10.3 'dependencies.string-width'^4.2.3
But we are moving to ESM (#5291) and will support ESM in the next major version (v16.0.0).
What minimal example or steps are needed to reproduce the bug?
What minimal configuration is needed to reproduce the bug?
Using:
How did you run Stylelint?
Which Stylelint-related dependencies are you using?
What did you expect to happen?
Lint won't return a runtime error.
What actually happened?
Do you have a proposal to fix the bug?
Upgrade
string-width
to its latest version.Currently used by
stylelint
:Latest version available:
The text was updated successfully, but these errors were encountered: