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

build: allow stylelint@^16.0.0 in peerDependencies #25

Closed
wants to merge 1 commit into from
Closed

build: allow stylelint@^16.0.0 in peerDependencies #25

wants to merge 1 commit into from

Conversation

DaveLak
Copy link

@DaveLak DaveLak commented Dec 17, 2023

📒 Description

This upgrades the stylelint devDependency to version 16, but they removed support for Node.js versions less than 18.12.0 (because Node.js 14 and 16 have reached end-of-life) and refactored their code to use ESM so the other changes were necessary and described in the stylelint migration guide.

🚀 Changes

NOTE: there is still more refactoring (outlined in the migration doc lined above) to required in this project given stylelint has deprecated the CommonJS API, but this should be enough to at least get onto 16 in the meantime 🙂

🔐 Closes

#24

⛳️ Testing

  1. Ran npx ls-engines@latest to verify the dependency graph's stated "engines" criteria is met.
ls-engines Output
engine Currently available latest release of each valid major version:
node v21.4.0, v20.10.0, v19.9.0, v18.19.0
package engines: dependency graph engines:
"engines": { "engines": {
"node": ">= 18.12.0" "node": ">= 18.12"
} }

Your “engines” field exactly matches your dependency graph’s requirements!

engine current version valid (package) valid (dependency graph)
node v20.10.0 yes! yes!
  1. Ran npm run test before and after changes.
Test Suites: 1 passed, 1 total
Tests:       88 passed, 88 total
Snapshots:   0 total
Time:        0.893 s, estimated 1 s
Ran all test suites.

Upgrade stylelint devDependency to 16, but removed support for
Node.js less than 18.12.0 and refactored their code to use ESM so the
other changes were necessary and [described in the stylelint migration
guide][1].

[1]: https://github.com/stylelint/stylelint/blob/16.0.0/docs/migration-guide/to-16.md
@yuschick
Copy link
Owner

Thank you for this! This is a big help. Were you able to verify this works in v15 as well as v16 now? If not, I will test this out locally as well to ensure we have support for both the pre- and post- v16 updates.

@yuschick
Copy link
Owner

Thank you for doing this! It seems good to me, so once we get the CI to pass we will be good to go 👏

@yuschick
Copy link
Owner

yuschick commented Dec 22, 2023

Looks like there is an issue still with jest-preset-stylelint that is preventing the tests from running as expected. 🤔

@DaveLak Do you have any ideas?

@yuschick
Copy link
Owner

Looks like it's a Jest error right now.

A jest worker process (pid=41244) was terminated by another process: signal=SIGSEGV, exitCode=null. Operating system logs may contain more information on why this occurred.

@yuschick yuschick self-requested a review December 22, 2023 17:30
@yuschick
Copy link
Owner

@DaveLak @Israel-Laguan I am closing this PR and deferring to the more robust PR here: #28

This is where the package is updated to properly align with Stylelint 16. Trying to work out a small issue with my husly/commit-lint setup, but the tests for v16 are now passing.

@yuschick yuschick closed this Dec 28, 2023
@DaveLak
Copy link
Author

DaveLak commented Dec 30, 2023

@DaveLak @Israel-Laguan I am closing this PR and deferring to the more robust PR here: #28

This is where the package is updated to properly align with Stylelint 16. Trying to work out a small issue with my husly/commit-lint setup, but the tests for v16 are now passing.

Thanks, @yuschick! Sorry I missed that and was slow to respond (holiday season and all 😅)

@DaveLak DaveLak deleted the bump-styleint-peer-dependency branch December 30, 2023 03:11
@yuschick
Copy link
Owner

Honestly, for the best. I shouldn't have even been looking at this over the holidays. But yeah, all good, and thank you for the help in moving this forward 🙌

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 this pull request may close these issues.

3 participants