Skip to content

Commit

Permalink
chore(#331): drop is-glob (#332)
Browse files Browse the repository at this point in the history
  • Loading branch information
SukkaW authored Dec 16, 2024
1 parent 0fd4eea commit ceadb10
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 17 deletions.
2 changes: 0 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,6 @@
"enhanced-resolve": "^5.15.0",
"get-tsconfig": "^4.7.5",
"is-bun-module": "^1.0.2",
"is-glob": "^4.0.3",
"stable-hash": "^0.0.4",
"tinyglobby": "^0.2.10"
},
Expand All @@ -94,7 +93,6 @@
"@mozilla/glean": "^3.0.0",
"@pkgr/rollup": "^4.1.3",
"@types/debug": "^4.1.12",
"@types/is-glob": "^4.0.4",
"@types/node": "^18.19.67",
"@types/unist": "^2.0.11",
"dummy.js": "link:dummy.js",
Expand Down
14 changes: 8 additions & 6 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,8 @@ import { createPathsMatcher, getTsconfig } from 'get-tsconfig'
import type { TsConfigResult } from 'get-tsconfig'
import type { Version } from 'is-bun-module'
import { isBunModule } from 'is-bun-module'
import isGlob from 'is-glob'
import stableHashExports from 'stable-hash'
import { globSync } from 'tinyglobby'
import { globSync, isDynamicPattern } from 'tinyglobby'

// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition -- esmodule interop
const stableHash = stableHashExports.default || stableHashExports
Expand Down Expand Up @@ -390,10 +389,13 @@ function initMappers(options: InternalResolverOptions) {
// turn glob patterns into paths
const projectPaths = [
...new Set([
...configPaths.filter(path => !isGlob(path)),
...globSync([...configPaths.filter(path => isGlob(path)), ...ignore], {
expandDirectories: false,
}),
...configPaths.filter(path => !isDynamicPattern(path)),
...globSync(
[...configPaths.filter(path => isDynamicPattern(path)), ...ignore],
{
expandDirectories: false,
},
),
]),
]

Expand Down
9 changes: 0 additions & 9 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3648,13 +3648,6 @@ __metadata:
languageName: node
linkType: hard

"@types/is-glob@npm:^4.0.4":
version: 4.0.4
resolution: "@types/is-glob@npm:4.0.4"
checksum: c790125e2d133d15c9783f6468995841cb06b5634b5c7b30aa32d23129f19d7dc271ec1a904bea4ca1e6a5ba19218a6602753d558f343b4fb8402fed25d17219
languageName: node
linkType: hard

"@types/json-schema@npm:^7.0.9":
version: 7.0.15
resolution: "@types/json-schema@npm:7.0.15"
Expand Down Expand Up @@ -6158,7 +6151,6 @@ __metadata:
"@nolyfill/is-core-module": "npm:1.0.39"
"@pkgr/rollup": "npm:^4.1.3"
"@types/debug": "npm:^4.1.12"
"@types/is-glob": "npm:^4.0.4"
"@types/node": "npm:^18.19.67"
"@types/unist": "npm:^2.0.11"
debug: "npm:^4.3.7"
Expand All @@ -6170,7 +6162,6 @@ __metadata:
eslint-plugin-import-x: "npm:^4.5.0"
get-tsconfig: "npm:^4.7.5"
is-bun-module: "npm:^1.0.2"
is-glob: "npm:^4.0.3"
lint-staged: "npm:^13.3.0"
npm-run-all2: "npm:^5.0.2"
prettier: "npm:^2.8.8"
Expand Down

0 comments on commit ceadb10

Please sign in to comment.