Skip to content

Commit 213e323

Browse files
committed
chore: switch to tinyglobby
1 parent e98250b commit 213e323

File tree

3 files changed

+9
-17
lines changed

3 files changed

+9
-17
lines changed

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -135,14 +135,14 @@
135135
"@vue-macros/common": "^1.16.1",
136136
"ast-walker-scope": "^0.6.2",
137137
"chokidar": "^4.0.3",
138-
"fast-glob": "^3.3.3",
139138
"json5": "^2.2.3",
140139
"local-pkg": "^1.0.0",
141140
"magic-string": "^0.30.17",
142141
"mlly": "^1.7.4",
143142
"pathe": "^2.0.2",
144143
"picomatch": "^4.0.2",
145144
"scule": "^1.3.0",
145+
"tinyglobby": "^0.2.12",
146146
"unplugin": "^2.2.0",
147147
"unplugin-utils": "^0.2.3",
148148
"yaml": "^2.7.0"

pnpm-lock.yaml

+5-14
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/core/context.ts

+3-2
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import { asRoutePath, ImportsMap, logTree, throttle } from './utils'
55
import { generateRouteNamedMap } from '../codegen/generateRouteMap'
66
import { MODULE_ROUTES_PATH, MODULE_VUE_ROUTER_AUTO } from './moduleConstants'
77
import { generateRouteRecord } from '../codegen/generateRouteRecords'
8-
import fg from 'fast-glob'
8+
import { glob } from 'tinyglobby'
99
import { dirname, relative, resolve } from 'pathe'
1010
import { ServerContext } from '../options'
1111
import { getRouteBlock } from './customBlock'
@@ -73,11 +73,12 @@ export function createRoutesContext(options: ResolvedOptions) {
7373
f.startsWith('**') ? f : relative(folder.src, f)
7474
)
7575

76-
return fg(folder.pattern, {
76+
return glob(folder.pattern, {
7777
cwd: folder.src,
7878
// TODO: do they return the symbolic link path or the original file?
7979
// followSymbolicLinks: false,
8080
ignore: ignorePattern,
81+
expandDirectories: false,
8182
}).then((files) =>
8283
Promise.all(
8384
files

0 commit comments

Comments
 (0)