Support TypeScript 5.2.2#338
Conversation
…/utils to support typescript 5.2.2
| "extends": "typesafeconfig", | ||
| "compilerOptions": { | ||
| "module": "commonjs", | ||
| "moduleResolution": "Bundler", |
There was a problem hiding this comment.
Added to allow TS to continue to pick up the correct types.
typescript-eslint/typescript-eslint#7284
Contains a warning when building, but appears to still produce the same output.
There was a problem hiding this comment.
Does this issue persist into v8 of @typescript-eslint/utils?
| "homepage": "https://github.com/shian15810/eslint-plugin-typescript-enum#readme", | ||
| "dependencies": { | ||
| "@typescript-eslint/experimental-utils": "^5.3.0" | ||
| "@typescript-eslint/utils": "^6.7.2" |
There was a problem hiding this comment.
This is the main change, and what removes the nested problematic tsutils package from the dependency tree: typescript-eslint/typescript-eslint#7155 (comment)
@shian15810 what do you think about this?
There was a problem hiding this comment.
Could you bump this to major version 8 of @typescript-eslint/utils? Its latest version is currently 8.18.0.
|
This is a breaking change as well for this package I guess, might need to bump the major version~ |
|
I'm thinking should I merge your PR and release a major version first before bumping @dominicfraser What do you think? |
|
Hi @shian15810 I tested updating to v8, and pushed a commit showing what that would look like: 34496c5. I've then reset it back to v6. I think your plan of merging with the v6 changes, doing a release, and then updating to v8 and doing another release is a good plan. It gives flexibility to people to be able to update in stages if they need to 👍 |
Context
TypeScript 5.2.2 comes with a breaking change that requires all
@typescript-eslint/*dependencies to move to >= v6: typescript-eslint/typescript-eslint#7155 (comment).In this repository that specifically means moving from
to
Changes
Add tests
To give more confidence that behaviour was preserved before and after making changes tests have been added.
This was done using the recommendations from https://typescript-eslint.io/developers/custom-rules#testing - use
@typescript-eslint/rule-testerpaired withvitest.These tests can be reverted if they are not desired.
Update to
@typescript-eslint/utilsandtypescript@5.2.2This is the main change, allowing this really helpful plugin to continue to be used with newer typescript.