From fce9c63f0a04927eed9ebe39cdbef7d6b1d75999 Mon Sep 17 00:00:00 2001 From: JounQin Date: Sun, 16 Mar 2025 17:13:52 +0800 Subject: [PATCH 1/3] fix: use `rspack-resolver` fork for pnp support --- package.json | 4 +- src/index.ts | 2 +- yarn.lock | 256 +++++++++++++++++++++++++-------------------------- 3 files changed, 131 insertions(+), 131 deletions(-) diff --git a/package.json b/package.json index c0061bb..33a57e8 100644 --- a/package.json +++ b/package.json @@ -85,7 +85,7 @@ "debug": "^4.4.0", "get-tsconfig": "^4.10.0", "is-bun-module": "^1.3.0", - "oxc-resolver": "^5.0.0", + "rspack-resolver": "^1.1.0", "stable-hash": "^0.0.5", "tinyglobby": "^0.2.12" }, @@ -104,7 +104,7 @@ "dummy.js": "link:dummy.js", "eslint": "^9.22.0", "eslint-import-resolver-typescript": "link:.", - "eslint-plugin-import-x": "^4.7.0", + "eslint-plugin-import-x": "^4.7.2", "lint-staged": "^15.5.0", "npm-run-all2": "^7.0.2", "prettier": "^3.5.3", diff --git a/src/index.ts b/src/index.ts index dfd3411..e771d69 100644 --- a/src/index.ts +++ b/src/index.ts @@ -7,7 +7,7 @@ import type { TsConfigResult } from 'get-tsconfig' import { createPathsMatcher, getTsconfig } from 'get-tsconfig' import type { Version } from 'is-bun-module' import { isBunModule } from 'is-bun-module' -import { type NapiResolveOptions, ResolverFactory } from 'oxc-resolver' +import { type NapiResolveOptions, ResolverFactory } from 'rspack-resolver' import { stableHash } from 'stable-hash' import { globSync, isDynamicPattern } from 'tinyglobby' import type { SetRequired } from 'type-fest' diff --git a/yarn.lock b/yarn.lock index 6ef0e9b..eade6b9 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3376,85 +3376,6 @@ __metadata: languageName: node linkType: hard -"@oxc-resolver/binding-darwin-arm64@npm:5.0.0": - version: 5.0.0 - resolution: "@oxc-resolver/binding-darwin-arm64@npm:5.0.0" - conditions: os=darwin & cpu=arm64 - languageName: node - linkType: hard - -"@oxc-resolver/binding-darwin-x64@npm:5.0.0": - version: 5.0.0 - resolution: "@oxc-resolver/binding-darwin-x64@npm:5.0.0" - conditions: os=darwin & cpu=x64 - languageName: node - linkType: hard - -"@oxc-resolver/binding-freebsd-x64@npm:5.0.0": - version: 5.0.0 - resolution: "@oxc-resolver/binding-freebsd-x64@npm:5.0.0" - conditions: os=freebsd & cpu=x64 - languageName: node - linkType: hard - -"@oxc-resolver/binding-linux-arm-gnueabihf@npm:5.0.0": - version: 5.0.0 - resolution: "@oxc-resolver/binding-linux-arm-gnueabihf@npm:5.0.0" - conditions: os=linux & cpu=arm - languageName: node - linkType: hard - -"@oxc-resolver/binding-linux-arm64-gnu@npm:5.0.0": - version: 5.0.0 - resolution: "@oxc-resolver/binding-linux-arm64-gnu@npm:5.0.0" - conditions: os=linux & cpu=arm64 & libc=glibc - languageName: node - linkType: hard - -"@oxc-resolver/binding-linux-arm64-musl@npm:5.0.0": - version: 5.0.0 - resolution: "@oxc-resolver/binding-linux-arm64-musl@npm:5.0.0" - conditions: os=linux & cpu=arm64 & libc=musl - languageName: node - linkType: hard - -"@oxc-resolver/binding-linux-x64-gnu@npm:5.0.0": - version: 5.0.0 - resolution: "@oxc-resolver/binding-linux-x64-gnu@npm:5.0.0" - conditions: os=linux & cpu=x64 & libc=glibc - languageName: node - linkType: hard - -"@oxc-resolver/binding-linux-x64-musl@npm:5.0.0": - version: 5.0.0 - resolution: "@oxc-resolver/binding-linux-x64-musl@npm:5.0.0" - conditions: os=linux & cpu=x64 & libc=musl - languageName: node - linkType: hard - -"@oxc-resolver/binding-wasm32-wasi@npm:5.0.0": - version: 5.0.0 - resolution: "@oxc-resolver/binding-wasm32-wasi@npm:5.0.0" - dependencies: - "@napi-rs/wasm-runtime": "npm:^0.2.7" - conditions: cpu=wasm32 - languageName: node - linkType: hard - -"@oxc-resolver/binding-win32-arm64-msvc@npm:5.0.0": - version: 5.0.0 - resolution: "@oxc-resolver/binding-win32-arm64-msvc@npm:5.0.0" - conditions: os=win32 & cpu=arm64 - languageName: node - linkType: hard - -"@oxc-resolver/binding-win32-x64-msvc@npm:5.0.0": - version: 5.0.0 - resolution: "@oxc-resolver/binding-win32-x64-msvc@npm:5.0.0" - conditions: os=win32 & cpu=x64 - languageName: node - linkType: hard - "@pkgjs/parseargs@npm:^0.11.0": version: 0.11.0 resolution: "@pkgjs/parseargs@npm:0.11.0" @@ -4320,6 +4241,85 @@ __metadata: languageName: node linkType: hard +"@unrs/rspack-resolver-binding-darwin-arm64@npm:1.1.0": + version: 1.1.0 + resolution: "@unrs/rspack-resolver-binding-darwin-arm64@npm:1.1.0" + conditions: os=darwin & cpu=arm64 + languageName: node + linkType: hard + +"@unrs/rspack-resolver-binding-darwin-x64@npm:1.1.0": + version: 1.1.0 + resolution: "@unrs/rspack-resolver-binding-darwin-x64@npm:1.1.0" + conditions: os=darwin & cpu=x64 + languageName: node + linkType: hard + +"@unrs/rspack-resolver-binding-freebsd-x64@npm:1.1.0": + version: 1.1.0 + resolution: "@unrs/rspack-resolver-binding-freebsd-x64@npm:1.1.0" + conditions: os=freebsd & cpu=x64 + languageName: node + linkType: hard + +"@unrs/rspack-resolver-binding-linux-arm-gnueabihf@npm:1.1.0": + version: 1.1.0 + resolution: "@unrs/rspack-resolver-binding-linux-arm-gnueabihf@npm:1.1.0" + conditions: os=linux & cpu=arm + languageName: node + linkType: hard + +"@unrs/rspack-resolver-binding-linux-arm64-gnu@npm:1.1.0": + version: 1.1.0 + resolution: "@unrs/rspack-resolver-binding-linux-arm64-gnu@npm:1.1.0" + conditions: os=linux & cpu=arm64 & libc=glibc + languageName: node + linkType: hard + +"@unrs/rspack-resolver-binding-linux-arm64-musl@npm:1.1.0": + version: 1.1.0 + resolution: "@unrs/rspack-resolver-binding-linux-arm64-musl@npm:1.1.0" + conditions: os=linux & cpu=arm64 & libc=musl + languageName: node + linkType: hard + +"@unrs/rspack-resolver-binding-linux-x64-gnu@npm:1.1.0": + version: 1.1.0 + resolution: "@unrs/rspack-resolver-binding-linux-x64-gnu@npm:1.1.0" + conditions: os=linux & cpu=x64 & libc=glibc + languageName: node + linkType: hard + +"@unrs/rspack-resolver-binding-linux-x64-musl@npm:1.1.0": + version: 1.1.0 + resolution: "@unrs/rspack-resolver-binding-linux-x64-musl@npm:1.1.0" + conditions: os=linux & cpu=x64 & libc=musl + languageName: node + linkType: hard + +"@unrs/rspack-resolver-binding-wasm32-wasi@npm:1.1.0": + version: 1.1.0 + resolution: "@unrs/rspack-resolver-binding-wasm32-wasi@npm:1.1.0" + dependencies: + "@napi-rs/wasm-runtime": "npm:^0.2.7" + conditions: cpu=wasm32 + languageName: node + linkType: hard + +"@unrs/rspack-resolver-binding-win32-arm64-msvc@npm:1.1.0": + version: 1.1.0 + resolution: "@unrs/rspack-resolver-binding-win32-arm64-msvc@npm:1.1.0" + conditions: os=win32 & cpu=arm64 + languageName: node + linkType: hard + +"@unrs/rspack-resolver-binding-win32-x64-msvc@npm:1.1.0": + version: 1.1.0 + resolution: "@unrs/rspack-resolver-binding-win32-x64-msvc@npm:1.1.0" + conditions: os=win32 & cpu=x64 + languageName: node + linkType: hard + "@vue/babel-helper-vue-jsx-merge-props@npm:^1.4.0": version: 1.4.0 resolution: "@vue/babel-helper-vue-jsx-merge-props@npm:1.4.0" @@ -6700,14 +6700,14 @@ __metadata: dummy.js: "link:dummy.js" eslint: "npm:^9.22.0" eslint-import-resolver-typescript: "link:." - eslint-plugin-import-x: "npm:^4.7.0" + eslint-plugin-import-x: "npm:^4.7.2" get-tsconfig: "npm:^4.10.0" is-bun-module: "npm:^1.3.0" lint-staged: "npm:^15.5.0" npm-run-all2: "npm:^7.0.2" - oxc-resolver: "npm:^5.0.0" prettier: "npm:^3.5.3" react: "npm:^19.0.0" + rspack-resolver: "npm:^1.1.0" simple-git-hooks: "npm:^2.11.1" size-limit: "npm:^11.2.0" size-limit-preset-node-lib: "npm:^0.3.0" @@ -6796,9 +6796,9 @@ __metadata: languageName: node linkType: hard -"eslint-plugin-import-x@npm:^4.6.1, eslint-plugin-import-x@npm:^4.7.0": - version: 4.7.0 - resolution: "eslint-plugin-import-x@npm:4.7.0" +"eslint-plugin-import-x@npm:^4.6.1, eslint-plugin-import-x@npm:^4.7.2": + version: 4.7.2 + resolution: "eslint-plugin-import-x@npm:4.7.2" dependencies: "@types/doctrine": "npm:^0.0.9" "@typescript-eslint/utils": "npm:^8.26.1" @@ -6808,13 +6808,13 @@ __metadata: get-tsconfig: "npm:^4.10.0" is-glob: "npm:^4.0.3" minimatch: "npm:^10.0.1" - oxc-resolver: "npm:^5.0.0" + rspack-resolver: "npm:^1.1.0" semver: "npm:^7.7.1" stable-hash: "npm:^0.0.5" tslib: "npm:^2.8.1" peerDependencies: eslint: ^8.57.0 || ^9.0.0 - checksum: 10/183c92c526d01d8b40debe49a01a287fabdc75ec0f0d678e4a88570767a3aa8ab2e3659a7ae8b7dd10d36266aad62ff9b0719f5414abefd63728e6d0e3e966e5 + checksum: 10/866ef0301576310fb55a07748909373d93593bc891ef869e05a6122ffc1dc60b609aa016a70a4be1ff9186d9608422357e2949d7f09a6e38d6d95a494e9b8805 languageName: node linkType: hard @@ -11267,48 +11267,6 @@ __metadata: languageName: node linkType: hard -"oxc-resolver@npm:^5.0.0": - version: 5.0.0 - resolution: "oxc-resolver@npm:5.0.0" - dependencies: - "@oxc-resolver/binding-darwin-arm64": "npm:5.0.0" - "@oxc-resolver/binding-darwin-x64": "npm:5.0.0" - "@oxc-resolver/binding-freebsd-x64": "npm:5.0.0" - "@oxc-resolver/binding-linux-arm-gnueabihf": "npm:5.0.0" - "@oxc-resolver/binding-linux-arm64-gnu": "npm:5.0.0" - "@oxc-resolver/binding-linux-arm64-musl": "npm:5.0.0" - "@oxc-resolver/binding-linux-x64-gnu": "npm:5.0.0" - "@oxc-resolver/binding-linux-x64-musl": "npm:5.0.0" - "@oxc-resolver/binding-wasm32-wasi": "npm:5.0.0" - "@oxc-resolver/binding-win32-arm64-msvc": "npm:5.0.0" - "@oxc-resolver/binding-win32-x64-msvc": "npm:5.0.0" - dependenciesMeta: - "@oxc-resolver/binding-darwin-arm64": - optional: true - "@oxc-resolver/binding-darwin-x64": - optional: true - "@oxc-resolver/binding-freebsd-x64": - optional: true - "@oxc-resolver/binding-linux-arm-gnueabihf": - optional: true - "@oxc-resolver/binding-linux-arm64-gnu": - optional: true - "@oxc-resolver/binding-linux-arm64-musl": - optional: true - "@oxc-resolver/binding-linux-x64-gnu": - optional: true - "@oxc-resolver/binding-linux-x64-musl": - optional: true - "@oxc-resolver/binding-wasm32-wasi": - optional: true - "@oxc-resolver/binding-win32-arm64-msvc": - optional: true - "@oxc-resolver/binding-win32-x64-msvc": - optional: true - checksum: 10/b3809bf78d736a3fd3d1038baf97d59428205b2973f120971f85b65f7fd73783fb0f1554c9a0f5dd70cc9a07a47ec72f83c6ed943f7e792221ef59d22fffc233 - languageName: node - linkType: hard - "p-cancelable@npm:^2.0.0": version: 2.1.1 resolution: "p-cancelable@npm:2.1.1" @@ -13265,6 +13223,48 @@ __metadata: languageName: node linkType: hard +"rspack-resolver@npm:^1.1.0": + version: 1.1.0 + resolution: "rspack-resolver@npm:1.1.0" + dependencies: + "@unrs/rspack-resolver-binding-darwin-arm64": "npm:1.1.0" + "@unrs/rspack-resolver-binding-darwin-x64": "npm:1.1.0" + "@unrs/rspack-resolver-binding-freebsd-x64": "npm:1.1.0" + "@unrs/rspack-resolver-binding-linux-arm-gnueabihf": "npm:1.1.0" + "@unrs/rspack-resolver-binding-linux-arm64-gnu": "npm:1.1.0" + "@unrs/rspack-resolver-binding-linux-arm64-musl": "npm:1.1.0" + "@unrs/rspack-resolver-binding-linux-x64-gnu": "npm:1.1.0" + "@unrs/rspack-resolver-binding-linux-x64-musl": "npm:1.1.0" + "@unrs/rspack-resolver-binding-wasm32-wasi": "npm:1.1.0" + "@unrs/rspack-resolver-binding-win32-arm64-msvc": "npm:1.1.0" + "@unrs/rspack-resolver-binding-win32-x64-msvc": "npm:1.1.0" + dependenciesMeta: + "@unrs/rspack-resolver-binding-darwin-arm64": + optional: true + "@unrs/rspack-resolver-binding-darwin-x64": + optional: true + "@unrs/rspack-resolver-binding-freebsd-x64": + optional: true + "@unrs/rspack-resolver-binding-linux-arm-gnueabihf": + optional: true + "@unrs/rspack-resolver-binding-linux-arm64-gnu": + optional: true + "@unrs/rspack-resolver-binding-linux-arm64-musl": + optional: true + "@unrs/rspack-resolver-binding-linux-x64-gnu": + optional: true + "@unrs/rspack-resolver-binding-linux-x64-musl": + optional: true + "@unrs/rspack-resolver-binding-wasm32-wasi": + optional: true + "@unrs/rspack-resolver-binding-win32-arm64-msvc": + optional: true + "@unrs/rspack-resolver-binding-win32-x64-msvc": + optional: true + checksum: 10/b8582e0d28596ba9ed8a4cd19b04b6e96e0e0963cdc0d5f365fc7d46335e5bbdb44ef433c2e0a560dedb3f4cd55cc13788f1d3b223f83cf4a3a7f8550b96e305 + languageName: node + linkType: hard + "run-parallel@npm:^1.1.9": version: 1.2.0 resolution: "run-parallel@npm:1.2.0" From 1dae7b67c4605351b2670e28495f9731bea703ad Mon Sep 17 00:00:00 2001 From: JounQin Date: Sun, 16 Mar 2025 18:00:55 +0800 Subject: [PATCH 2/3] refactor: remove some unnecessary codes --- package.json | 4 +++- src/global.d.ts | 8 ++++++++ src/index.ts | 50 ++++++++++++++++++++++++------------------------- yarn.lock | 40 ++++++++++++++++++++++----------------- 4 files changed, 58 insertions(+), 44 deletions(-) create mode 100644 src/global.d.ts diff --git a/package.json b/package.json index 33a57e8..389603d 100644 --- a/package.json +++ b/package.json @@ -96,15 +96,17 @@ "@commitlint/cli": "^19.8.0", "@mozilla/glean": "^5.0.3", "@pkgr/rollup": "^6.0.0", + "@total-typescript/ts-reset": "^0.6.1", "@types/debug": "^4.1.12", "@types/node": "^22.13.10", + "@types/pnpapi": "^0.0.5", "@types/unist": "^3.0.3", "clean-pkg-json": "^1.2.1", "cross-env": "^7.0.3", "dummy.js": "link:dummy.js", "eslint": "^9.22.0", "eslint-import-resolver-typescript": "link:.", - "eslint-plugin-import-x": "^4.7.2", + "eslint-plugin-import-x": "^4.8.0", "lint-staged": "^15.5.0", "npm-run-all2": "^7.0.2", "prettier": "^3.5.3", diff --git a/src/global.d.ts b/src/global.d.ts new file mode 100644 index 0000000..09a1ba5 --- /dev/null +++ b/src/global.d.ts @@ -0,0 +1,8 @@ +import '@total-typescript/ts-reset' +import type * as pnpapi from 'pnpapi' + +declare module 'module' { + namespace Module { + function findPnpApi(source: string): typeof pnpapi + } +} diff --git a/src/index.ts b/src/index.ts index e771d69..8efc987 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,4 +1,5 @@ import fs from 'node:fs' +import module from 'node:module' import path from 'node:path' import isNodeCoreModule from '@nolyfill/is-core-module' @@ -94,7 +95,7 @@ let previousOptionsHash: string let optionsHash: string let cachedOptions: InternalResolverOptions | undefined -let prevCwd: string +let cachedCwd: string let mappersCachedOptions: InternalResolverOptions let mappers: Array<{ @@ -160,6 +161,18 @@ export function resolve( } } + /** + * {@link https://github.com/webpack/enhanced-resolve/blob/38e9fd9acb79643a70e7bcd0d85dabc600ea321f/lib/PnpPlugin.js#L81-L83} + */ + if (process.versions.pnp && source === 'pnpapi') { + return { + found: true, + path: module.findPnpApi(file).resolveToUnqualified(source, file, { + considerBuiltins: false, + }), + } + } + initMappers(cachedOptions) let mappedPaths = getMappedPaths(source, file, cachedOptions.extensions, true) @@ -383,18 +396,18 @@ function initMappers(options: InternalResolverOptions) { if ( mappers.length > 0 && mappersCachedOptions === options && - prevCwd === process.cwd() + cachedCwd === process.cwd() ) { return } - prevCwd = process.cwd() + cachedCwd = process.cwd() const configPaths = ( typeof options.project === 'string' ? [options.project] : // eslint-disable-next-line sonarjs/no-nested-conditional Array.isArray(options.project) ? options.project - : [process.cwd()] + : [cachedCwd] ) // 'tinyglobby' pattern must have POSIX separator .map(config => replacePathSeparator(config, path.sep, path.posix.sep)) @@ -432,20 +445,18 @@ function initMappers(options: InternalResolverOptions) { } if (!tsconfigResult) { - // eslint-disable-next-line unicorn/no-useless-undefined - return undefined + return } const mapperFn = createPathsMatcher(tsconfigResult) if (!mapperFn) { - // eslint-disable-next-line unicorn/no-useless-undefined - return undefined + return } const files = - tsconfigResult.config.files === undefined && - tsconfigResult.config.include === undefined + tsconfigResult.config.files == null && + tsconfigResult.config.include == null ? // Include everything if no files or include options globSync(defaultInclude, { absolute: true, @@ -458,7 +469,7 @@ function initMappers(options: InternalResolverOptions) { }) : [ // https://www.typescriptlang.org/tsconfig/#files - ...(tsconfigResult.config.files !== undefined && + ...(tsconfigResult.config.files != null && tsconfigResult.config.files.length > 0 ? tsconfigResult.config.files.map(file => path.normalize( @@ -467,7 +478,7 @@ function initMappers(options: InternalResolverOptions) { ) : []), // https://www.typescriptlang.org/tsconfig/#include - ...(tsconfigResult.config.include !== undefined && + ...(tsconfigResult.config.include != null && tsconfigResult.config.include.length > 0 ? globSync(tsconfigResult.config.include, { absolute: true, @@ -487,7 +498,7 @@ function initMappers(options: InternalResolverOptions) { mapperFn, } }) - .filter(isDefined) + .filter(Boolean) mappersCachedOptions = options } @@ -535,19 +546,6 @@ function toNativePathSeparator(p: string) { ) } -/** - * Check if value is defined. - * - * Helper function for TypeScript. - * Should be removed when upgrading to TypeScript >= 5.5. - * - * @param {T | null | undefined} value Value - * @returns `true` if value is defined, `false` otherwise - */ -function isDefined(value: T | null | undefined): value is T { - return value !== null && value !== undefined -} - /** * Counts how many characters in strings `a` and `b` are exactly the same and in the same position. * diff --git a/yarn.lock b/yarn.lock index eade6b9..5217fbc 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3771,6 +3771,13 @@ __metadata: languageName: node linkType: hard +"@total-typescript/ts-reset@npm:^0.6.1": + version: 0.6.1 + resolution: "@total-typescript/ts-reset@npm:0.6.1" + checksum: 10/3e18063433c4667561b2a5ea6b698d95f8ca2cbecc7e3717b60f9266e2fd7070b2006cab0df255e60eaad5658d1cec4afc89ea4ca5645c8f36a312093bba3645 + languageName: node + linkType: hard + "@tsconfig/node10@npm:^1.0.7": version: 1.0.11 resolution: "@tsconfig/node10@npm:1.0.11" @@ -4050,6 +4057,13 @@ __metadata: languageName: node linkType: hard +"@types/pnpapi@npm:^0.0.5": + version: 0.0.5 + resolution: "@types/pnpapi@npm:0.0.5" + checksum: 10/46d8474b77358c8cc48b957c059de6ad0839d18d8e90252c500c6bc30702e44e2629cf330350f7b291f35d863190b5390b641992c0601853a5d8b129fa91bd4d + languageName: node + linkType: hard + "@types/resolve@npm:1.20.2": version: 1.20.2 resolution: "@types/resolve@npm:1.20.2" @@ -6691,8 +6705,10 @@ __metadata: "@mozilla/glean": "npm:^5.0.3" "@nolyfill/is-core-module": "npm:1.0.39" "@pkgr/rollup": "npm:^6.0.0" + "@total-typescript/ts-reset": "npm:^0.6.1" "@types/debug": "npm:^4.1.12" "@types/node": "npm:^22.13.10" + "@types/pnpapi": "npm:^0.0.5" "@types/unist": "npm:^3.0.3" clean-pkg-json: "npm:^1.2.1" cross-env: "npm:^7.0.3" @@ -6700,7 +6716,7 @@ __metadata: dummy.js: "link:dummy.js" eslint: "npm:^9.22.0" eslint-import-resolver-typescript: "link:." - eslint-plugin-import-x: "npm:^4.7.2" + eslint-plugin-import-x: "npm:^4.8.0" get-tsconfig: "npm:^4.10.0" is-bun-module: "npm:^1.3.0" lint-staged: "npm:^15.5.0" @@ -6796,9 +6812,9 @@ __metadata: languageName: node linkType: hard -"eslint-plugin-import-x@npm:^4.6.1, eslint-plugin-import-x@npm:^4.7.2": - version: 4.7.2 - resolution: "eslint-plugin-import-x@npm:4.7.2" +"eslint-plugin-import-x@npm:^4.6.1, eslint-plugin-import-x@npm:^4.8.0": + version: 4.8.0 + resolution: "eslint-plugin-import-x@npm:4.8.0" dependencies: "@types/doctrine": "npm:^0.0.9" "@typescript-eslint/utils": "npm:^8.26.1" @@ -6806,15 +6822,14 @@ __metadata: doctrine: "npm:^3.0.0" eslint-import-resolver-node: "npm:^0.3.9" get-tsconfig: "npm:^4.10.0" - is-glob: "npm:^4.0.3" - minimatch: "npm:^10.0.1" + picomatch: "npm:^4.0.2" rspack-resolver: "npm:^1.1.0" semver: "npm:^7.7.1" stable-hash: "npm:^0.0.5" tslib: "npm:^2.8.1" peerDependencies: eslint: ^8.57.0 || ^9.0.0 - checksum: 10/866ef0301576310fb55a07748909373d93593bc891ef869e05a6122ffc1dc60b609aa016a70a4be1ff9186d9608422357e2949d7f09a6e38d6d95a494e9b8805 + checksum: 10/ab0fe7b33a8c0f08ba7e7f0a4e0a7421f82f15688b775d6cd6dcd7b84ab5a511fd35bb6dd026156ff12b83b2be0b3d185638a1c886ecbd12979efafc0a298428 languageName: node linkType: hard @@ -10648,16 +10663,7 @@ __metadata: languageName: node linkType: hard -"minimatch@npm:6 || 7 || 8 || 9 || 10, minimatch@npm:^10.0.1": - version: 10.0.1 - resolution: "minimatch@npm:10.0.1" - dependencies: - brace-expansion: "npm:^2.0.1" - checksum: 10/082e7ccbc090d5f8c4e4e029255d5a1d1e3af37bda837da2b8b0085b1503a1210c91ac90d9ebfe741d8a5f286ece820a1abb4f61dc1f82ce602a055d461d93f3 - languageName: node - linkType: hard - -"minimatch@npm:9.0.5, minimatch@npm:^9.0.0, minimatch@npm:^9.0.3, minimatch@npm:^9.0.4, minimatch@npm:^9.0.5": +"minimatch@npm:6 || 7 || 8 || 9 || 10, minimatch@npm:9.0.5, minimatch@npm:^9.0.0, minimatch@npm:^9.0.3, minimatch@npm:^9.0.4, minimatch@npm:^9.0.5": version: 9.0.5 resolution: "minimatch@npm:9.0.5" dependencies: From 5b748253a949ef59b33bd58293f83885fc24ec53 Mon Sep 17 00:00:00 2001 From: JounQin Date: Sun, 16 Mar 2025 18:02:03 +0800 Subject: [PATCH 3/3] Create cool-apes-juggle.md --- .changeset/cool-apes-juggle.md | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 .changeset/cool-apes-juggle.md diff --git a/.changeset/cool-apes-juggle.md b/.changeset/cool-apes-juggle.md new file mode 100644 index 0000000..28c237c --- /dev/null +++ b/.changeset/cool-apes-juggle.md @@ -0,0 +1,5 @@ +--- +"eslint-import-resolver-typescript": patch +--- + +fix: use `rspack-resolver` fork for pnp support