@angular/build 22.2.2 → 22.2.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +3 -3
- package/src/builders/application/index-html-generator.js +6 -1
- package/src/builders/application/index-html-generator.js.map +1 -1
- package/src/builders/application/options.js +2 -2
- package/src/builders/application/options.js.map +1 -1
- package/src/builders/application/schema.json +1 -1
- package/src/builders/dev-server/schema.d.ts +4 -3
- package/src/builders/dev-server/schema.json +2 -2
- package/src/builders/dev-server/vite/index.js +6 -0
- package/src/builders/dev-server/vite/index.js.map +1 -1
- package/src/builders/extract-i18n/application-extraction.js +1 -0
- package/src/builders/extract-i18n/application-extraction.js.map +1 -1
- package/src/builders/karma/schema.json +2 -2
- package/src/builders/unit-test/runners/karma/executor.js +1 -1
- package/src/builders/unit-test/runners/karma/executor.js.map +1 -1
- package/src/builders/unit-test/runners/vitest/browser-provider.js +2 -1
- package/src/builders/unit-test/runners/vitest/browser-provider.js.map +1 -1
- package/src/builders/unit-test/runners/vitest/executor.js +0 -5
- package/src/builders/unit-test/runners/vitest/executor.js.map +1 -1
- package/src/builders/unit-test/runners/vitest/plugins.js +12 -0
- package/src/builders/unit-test/runners/vitest/plugins.js.map +1 -1
- package/src/builders/unit-test/schema.d.ts +4 -4
- package/src/builders/unit-test/schema.json +1 -1
- package/src/builders/unit-test/test-discovery.js +4 -2
- package/src/builders/unit-test/test-discovery.js.map +1 -1
- package/src/tools/angular/angular-host.js +7 -2
- package/src/tools/angular/angular-host.js.map +1 -1
- package/src/tools/angular/compilation/aot-compilation.js +2 -1
- package/src/tools/angular/compilation/aot-compilation.js.map +1 -1
- package/src/tools/angular/compilation/compiler-options.d.ts +1 -0
- package/src/tools/angular/compilation/compiler-options.js +4 -2
- package/src/tools/angular/compilation/compiler-options.js.map +1 -1
- package/src/tools/angular/compilation/diagnostics.js +2 -2
- package/src/tools/angular/compilation/diagnostics.js.map +1 -1
- package/src/tools/esbuild/angular/compiler-plugin.js +2 -0
- package/src/tools/esbuild/angular/compiler-plugin.js.map +1 -1
- package/src/tools/esbuild/angular/component-stylesheets.js +14 -1
- package/src/tools/esbuild/angular/component-stylesheets.js.map +1 -1
- package/src/tools/esbuild/application-code-bundle.js +7 -5
- package/src/tools/esbuild/application-code-bundle.js.map +1 -1
- package/src/tools/esbuild/global-styles.js +3 -1
- package/src/tools/esbuild/global-styles.js.map +1 -1
- package/src/tools/esbuild/persistent-load-result-cache.js +2 -4
- package/src/tools/esbuild/persistent-load-result-cache.js.map +1 -1
- package/src/tools/esbuild/stylesheets/sass-language.js +18 -24
- package/src/tools/esbuild/stylesheets/sass-language.js.map +1 -1
- package/src/tools/sass/rebasing-importer.d.ts +1 -1
- package/src/tools/sass/rebasing-importer.js +6 -3
- package/src/tools/sass/rebasing-importer.js.map +1 -1
- package/src/utils/concurrency.d.ts +4 -0
- package/src/utils/concurrency.js +5 -0
- package/src/utils/concurrency.js.map +1 -1
- package/src/utils/index-file/nonce.d.ts +2 -1
- package/src/utils/index-file/nonce.js +22 -4
- package/src/utils/index-file/nonce.js.map +1 -1
- package/src/utils/load-proxy-config.js +27 -1
- package/src/utils/load-proxy-config.js.map +1 -1
- package/src/utils/normalize-cache.js +1 -1
- package/src/utils/resolve-assets.js +28 -9
- package/src/utils/resolve-assets.js.map +1 -1
- package/src/utils/server-rendering/esm-in-memory-loader/loader-hooks.d.ts +1 -1
- package/src/utils/server-rendering/esm-in-memory-loader/loader-hooks.js +3 -3
- package/src/utils/server-rendering/esm-in-memory-loader/loader-hooks.js.map +1 -1
- package/src/utils/server-rendering/esm-in-memory-loader/register-hooks.js +3 -2
- package/src/utils/server-rendering/esm-in-memory-loader/register-hooks.js.map +1 -1
- package/src/utils/watcher.d.ts +53 -0
- package/src/utils/watcher.js +521 -200
- package/src/utils/watcher.js.map +1 -1
package/src/utils/watcher.d.ts
CHANGED
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
* Use of this source code is governed by an MIT-style license that can be
|
|
6
6
|
* found in the LICENSE file at https://angular.dev/license
|
|
7
7
|
*/
|
|
8
|
+
import type * as ParcelWatcher from '@parcel/watcher';
|
|
8
9
|
export declare class ChangedFiles {
|
|
9
10
|
readonly added: Set<string>;
|
|
10
11
|
readonly modified: Set<string>;
|
|
@@ -66,3 +67,55 @@ export declare function isPathInside(file: string, dir: string): boolean;
|
|
|
66
67
|
* - `posixPath` must be a normalized POSIX-style path (using forward slashes '/').
|
|
67
68
|
*/
|
|
68
69
|
export declare function extractNodeModulesPackageDir(posixPath: string): string | undefined;
|
|
70
|
+
/**
|
|
71
|
+
* Manages `@parcel/watcher` directory subscriptions for watched files located outside the
|
|
72
|
+
* primary `workspaceRoot`.
|
|
73
|
+
*
|
|
74
|
+
* Because `@parcel/watcher` watches directories recursively and macOS limits each process to
|
|
75
|
+
* ~512 concurrent `FSEvents` streams, this manager:
|
|
76
|
+
* - Normalizes external `node_modules` file paths to their package root directory.
|
|
77
|
+
* - Batches synchronous `watchFile` and `removeFile` calls within a microtask before subscribing.
|
|
78
|
+
* - Uses a directory prefix tree to subsume nested child directories and iteratively coalesce
|
|
79
|
+
* deepest branching subdirectories into common ancestors when the subscription budget is exceeded.
|
|
80
|
+
* - Dynamically lowers its subscription budget and coalesces further if `subscribe()` fails on
|
|
81
|
+
* an existing directory due to OS stream limits.
|
|
82
|
+
*/
|
|
83
|
+
export declare class ParcelExternalManager {
|
|
84
|
+
#private;
|
|
85
|
+
/**
|
|
86
|
+
* Creates a new external directory subscription manager for `@parcel/watcher`.
|
|
87
|
+
*
|
|
88
|
+
* @param parcelWatcher The `@parcel/watcher` module.
|
|
89
|
+
* @param options Watcher configuration options.
|
|
90
|
+
* @param rootDirPosix Normalized POSIX path of the primary workspace root.
|
|
91
|
+
* @param rootDirLookupKey Case-normalized lookup key of the primary workspace root.
|
|
92
|
+
* @param isCaseSensitive Whether the filesystem at the workspace root is case-sensitive.
|
|
93
|
+
* @param handleEvents Callback to process incoming `@parcel/watcher` events.
|
|
94
|
+
* @param maxSubscriptions Maximum number of concurrent external directory subscriptions before coalescing.
|
|
95
|
+
*/
|
|
96
|
+
constructor(parcelWatcher: typeof ParcelWatcher, options: WatcherOptions | undefined, rootDirPosix: string, rootDirLookupKey: string, isCaseSensitive: boolean, handleEvents: (events: ParcelWatcher.Event[]) => void, maxSubscriptions?: number);
|
|
97
|
+
/**
|
|
98
|
+
* Registers a file path to be watched if it resides outside the primary workspace root,
|
|
99
|
+
* and schedules an asynchronous subscription reconciliation pass if needed.
|
|
100
|
+
*
|
|
101
|
+
* @param posixPath Normalized POSIX file path preserving original casing.
|
|
102
|
+
* @param lookupKey Case-normalized lookup key for the file path.
|
|
103
|
+
*/
|
|
104
|
+
watchFile(posixPath: string, lookupKey: string): void;
|
|
105
|
+
/**
|
|
106
|
+
* Unregisters a previously watched external file and schedules a reconciliation pass
|
|
107
|
+
* if it was the last watched file in its target directory.
|
|
108
|
+
*
|
|
109
|
+
* @param lookupKey Case-normalized lookup key for the file path to remove.
|
|
110
|
+
*/
|
|
111
|
+
removeFile(lookupKey: string): void;
|
|
112
|
+
/**
|
|
113
|
+
* Waits for any scheduled or in-progress subscription reconciliation pass to complete.
|
|
114
|
+
*/
|
|
115
|
+
flush(): Promise<void>;
|
|
116
|
+
/**
|
|
117
|
+
* Closes the manager, awaiting any pending reconciliation and unsubscribing all active
|
|
118
|
+
* external directory subscriptions.
|
|
119
|
+
*/
|
|
120
|
+
close(): Promise<void>;
|
|
121
|
+
}
|