Skip to content

Commit d65250b

Browse files
committed
refactor(@angular/build): switch to tinyglobby
1 parent 722c44f commit d65250b

File tree

7 files changed

+24
-15
lines changed

7 files changed

+24
-15
lines changed

packages/angular_devkit/build_angular/BUILD.bazel

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -198,10 +198,10 @@ ts_project(
198198
"//:node_modules/@types/watchpack",
199199
"//:node_modules/esbuild",
200200
"//:node_modules/esbuild-wasm",
201-
"//:node_modules/fast-glob",
202201
"//:node_modules/karma",
203202
"//:node_modules/karma-source-map-support",
204203
"//:node_modules/semver",
204+
"//:node_modules/tinyglobby",
205205
"//:node_modules/tslib",
206206
"//:node_modules/typescript",
207207
],
@@ -226,8 +226,8 @@ ts_project(
226226
":build_angular_test_utils",
227227
":node_modules/webpack",
228228
"//:node_modules/@types/node",
229-
"//:node_modules/fast-glob",
230229
"//:node_modules/prettier",
230+
"//:node_modules/tinyglobby",
231231
"//:node_modules/typescript",
232232
"//packages/angular_devkit/architect/testing",
233233
"//packages/angular_devkit/core",

packages/angular_devkit/build_angular/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929
"copy-webpack-plugin": "13.0.1",
3030
"css-loader": "7.1.2",
3131
"esbuild-wasm": "0.25.9",
32-
"fast-glob": "3.3.3",
3332
"http-proxy-middleware": "3.0.5",
3433
"istanbul-lib-instrument": "6.0.3",
3534
"jsonc-parser": "3.3.1",
@@ -53,6 +52,7 @@
5352
"source-map-loader": "5.0.0",
5453
"source-map-support": "0.5.21",
5554
"terser": "5.44.0",
55+
"tinyglobby": "0.2.15",
5656
"tree-kill": "1.2.2",
5757
"tslib": "2.8.1",
5858
"webpack": "5.101.3",

packages/angular_devkit/build_angular/src/tools/webpack/utils/helpers.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*/
88

99
import type { ObjectPattern } from 'copy-webpack-plugin';
10-
import glob from 'fast-glob';
10+
import { globSync } from 'tinyglobby';
1111
import { createHash } from 'node:crypto';
1212
import * as path from 'node:path';
1313
import type { Configuration, WebpackOptionsNormalized } from 'webpack';
@@ -126,7 +126,7 @@ export function getInstrumentationExcludedPaths(
126126

127127
for (const excludeGlob of excludedPaths) {
128128
const excludePath = excludeGlob[0] === '/' ? excludeGlob.slice(1) : excludeGlob;
129-
glob.sync(excludePath, { cwd: root }).forEach((p) => excluded.add(path.join(root, p)));
129+
globSync(excludePath, { cwd: root }).forEach((p) => excluded.add(path.join(root, p)));
130130
}
131131

132132
return excluded;

packages/angular_devkit/build_angular/src/utils/copy-assets.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
* found in the LICENSE file at https://angular.dev/license
77
*/
88

9-
import glob from 'fast-glob';
9+
import { glob } from 'tinyglobby';
1010
import fs from 'node:fs';
1111
import path from 'node:path';
1212

packages/angular_devkit/build_angular/src/utils/test-files.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
* found in the LICENSE file at https://angular.dev/license
77
*/
88

9-
import fastGlob, { Options as GlobOptions } from 'fast-glob';
9+
import { glob as globFn, GlobOptions } from 'tinyglobby';
1010

1111
/**
1212
* Finds all test files in the project.
@@ -21,7 +21,7 @@ export async function findTestFiles(
2121
include: string[],
2222
exclude: string[],
2323
workspaceRoot: string,
24-
glob: typeof fastGlob = fastGlob,
24+
glob: typeof globFn = globFn,
2525
): Promise<Set<string>> {
2626
const globOptions: GlobOptions = {
2727
cwd: workspaceRoot,

packages/angular_devkit/build_angular/src/utils/test-files_spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*/
88

99
// eslint-disable-next-line import/no-extraneous-dependencies
10-
import realGlob from 'fast-glob';
10+
import { glob as realGlob } from 'tinyglobby';
1111
import { promises as fs } from 'node:fs';
1212
import * as path from 'node:path';
1313
import { findTestFiles } from './test-files';

pnpm-lock.yaml

Lines changed: 15 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)