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

feat: refactor to ts, test against wider range of @typescript-eslint #89

Merged
merged 6 commits into from
Aug 8, 2024

Conversation

antfu
Copy link
Collaborator

@antfu antfu commented Jul 28, 2024

As #82 (comment)

I am sorry for a rather big PR, but changes are interconnected and I thought it would be better to do them all together. Happy to explain if you have any doubts. These changes allow us to have more confidence when introducing changes, and help with long term maintainability.

This PR changes:

  • Refactor the codebase to TypeScript and ESM
  • Publish both CJS and ESM
  • Migrate from jest to vitest (as it has better TS and ESM support)
  • Run a test matrix to also test against old versions of @typescript-eslint
  • Relax the version range of @typescript-eslint (as logic-wise there is no requirements on the version)
  • Switch to pnpm (better handling for package alias)
  • No longer deps on eslint-rule-composer, as it seems to be unmaintained, and we don't use a lot from it. It's simpler to direct do that in-house.
  • Removes engines field in package.json. As our code is rather pure and eslint itself would enforce the engines requirements already

@antfu antfu requested a review from sweepline July 28, 2024 10:03
@sweepline
Copy link
Owner

This is really nice, thanks!
I'm wondering if we could get away with just a minor version as its not breaking anything for version 4.x.x users?

@antfu
Copy link
Collaborator Author

antfu commented Aug 5, 2024

Totally, I think it would definitely be ok to be a minor version. I think it's more like how we communicate to the users.

README.md Outdated Show resolved Hide resolved
@antfu
Copy link
Collaborator Author

antfu commented Aug 7, 2024

@sweepline I think it should be good to go? Should I handle the merge and release? If so, can I have permission to the npm package (my id is antfu). Thanks!

@sweepline
Copy link
Owner

@antfu Yeah it looks good. I invited you on npm.

@antfu antfu merged commit 449a61e into master Aug 8, 2024
2 checks passed
@antfu antfu deleted the ts-refactor branch August 8, 2024 17:14
@clemens
Copy link

clemens commented Aug 9, 2024

Observation: In its current state, the README seems to be missing the information on what version 4.0.x is intended for. 3.x.x and 4.1.x are covered, but not 4.0.x.

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