Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Avoid Nullish coalescing operator to support old Node.js #205

Closed
ai opened this issue Aug 16, 2022 · 1 comment · Fixed by #215
Closed

Avoid Nullish coalescing operator to support old Node.js #205

ai opened this issue Aug 16, 2022 · 1 comment · Fixed by #215

Comments

@ai
Copy link
Collaborator

ai commented Aug 16, 2022

We are adding color.js to Stylelint for cool color-no-out-gamut-range rule.

But ?? operator from color.js sources breaks Node.js 12 and 14 support:

    /home/runner/work/stylelint/stylelint/node_modules/colorjs.io/dist/color.cjs:328
    		let coords = options.coords ?? this.base.coords;
    		                             ^

    SyntaxError: Unexpected token '?'
@LeaVerou
Copy link
Member

Hm, I suppose we could add Babel for the generated bundles and use a NodeJS 12 target.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants