@angular/compiler-cli 20.1.0-rc.0 → 20.1.1
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/bundles/{chunk-SEKYV57I.js → chunk-6HOSNZU5.js} +2 -3
- package/bundles/{chunk-FPHHL4UV.js → chunk-BPDNYZBC.js} +253 -49
- package/bundles/chunk-DWRM7PIK.js +14 -0
- package/bundles/{chunk-TPEB2IXF.js → chunk-GWZQLAGK.js} +35 -7
- package/bundles/{chunk-IRC3OLFO.js → chunk-GXMJGI7A.js} +2004 -554
- package/bundles/{chunk-PML5JK7B.js → chunk-HYJ2H3FU.js} +120 -7
- package/bundles/{chunk-6ECVYRSU.js → chunk-I2BHWRAU.js} +11 -6
- package/bundles/{chunk-QEIHQPSG.js → chunk-JWGODKML.js} +19 -7
- package/bundles/{chunk-SC5ESQGY.js → chunk-NA3RDKZL.js} +27 -11
- package/bundles/{chunk-3NKMA2JO.js → chunk-SZY7NM6F.js} +5 -6
- package/bundles/{chunk-45WGF6MF.js → chunk-WX5V4QZA.js} +656 -126
- package/bundles/index.js +34 -19
- package/bundles/linker/babel/index.js +70 -18
- package/bundles/linker/index.js +11 -5
- package/bundles/private/localize.js +5 -6
- package/bundles/private/migrations.js +5 -6
- package/bundles/private/tooling.js +27 -11
- package/bundles/src/bin/ng_xi18n.js +11 -12
- package/bundles/src/bin/ngc.js +9 -10
- package/linker/src/file_linker/partial_linkers/util.d.ts +1 -1
- package/package.json +3 -3
- package/src/ngtsc/docs/src/entities.d.ts +5 -1
- package/src/ngtsc/partial_evaluator/src/interpreter.d.ts +6 -3
- package/src/ngtsc/translator/src/typescript_ast_factory.d.ts +3 -0
- package/src/ngtsc/typecheck/src/expression.d.ts +2 -2
- package/src/ngtsc/typecheck/src/type_check_block.d.ts +2 -2
- package/bundles/chunk-2KXD3GSC.js +0 -34
- package/bundles/chunk-2KXD3GSC.js.map +0 -6
- package/bundles/chunk-3NKMA2JO.js.map +0 -6
- package/bundles/chunk-45WGF6MF.js.map +0 -6
- package/bundles/chunk-6ECVYRSU.js.map +0 -6
- package/bundles/chunk-FPHHL4UV.js.map +0 -6
- package/bundles/chunk-IRC3OLFO.js.map +0 -6
- package/bundles/chunk-KPQ72R34.js +0 -23
- package/bundles/chunk-KPQ72R34.js.map +0 -6
- package/bundles/chunk-PML5JK7B.js.map +0 -6
- package/bundles/chunk-QEIHQPSG.js.map +0 -6
- package/bundles/chunk-SC5ESQGY.js.map +0 -6
- package/bundles/chunk-SEKYV57I.js.map +0 -6
- package/bundles/chunk-TPEB2IXF.js.map +0 -6
- package/bundles/index.js.map +0 -6
- package/bundles/linker/babel/index.js.map +0 -6
- package/bundles/linker/index.js.map +0 -6
- package/bundles/private/localize.js.map +0 -6
- package/bundles/private/migrations.js.map +0 -6
- package/bundles/private/tooling.js.map +0 -6
- package/bundles/src/bin/ng_xi18n.js.map +0 -6
- package/bundles/src/bin/ngc.js.map +0 -6
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
|
|
2
|
+
import {createRequire as __cjsCompatRequire} from 'module';
|
|
3
|
+
const require = __cjsCompatRequire(import.meta.url);
|
|
4
|
+
|
|
5
|
+
var __require = /* @__PURE__ */ ((x) => typeof require !== "undefined" ? require : typeof Proxy !== "undefined" ? new Proxy(x, {
|
|
6
|
+
get: (a, b) => (typeof require !== "undefined" ? require : a)[b]
|
|
7
|
+
}) : x)(function(x) {
|
|
8
|
+
if (typeof require !== "undefined") return require.apply(this, arguments);
|
|
9
|
+
throw Error('Dynamic require of "' + x + '" is not supported');
|
|
10
|
+
});
|
|
11
|
+
|
|
12
|
+
export {
|
|
13
|
+
__require
|
|
14
|
+
};
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
const require = __cjsCompatRequire(import.meta.url);
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
//
|
|
6
|
+
// packages/compiler-cli/src/ngtsc/file_system/src/invalid_file_system.js
|
|
7
7
|
var InvalidFileSystem = class {
|
|
8
8
|
exists(path) {
|
|
9
9
|
throw makeError();
|
|
@@ -91,7 +91,7 @@ function makeError() {
|
|
|
91
91
|
return new Error("FileSystem has not been configured. Please call `setFileSystem()` before calling this method.");
|
|
92
92
|
}
|
|
93
93
|
|
|
94
|
-
//
|
|
94
|
+
// packages/compiler-cli/src/ngtsc/file_system/src/util.js
|
|
95
95
|
var TS_DTS_JS_EXTENSION = /(?:\.d)?\.ts$|\.js$/;
|
|
96
96
|
function normalizeSeparators(path) {
|
|
97
97
|
return path.replace(/\\/g, "/");
|
|
@@ -107,7 +107,7 @@ function getSourceFileOrError(program, fileName) {
|
|
|
107
107
|
return sf;
|
|
108
108
|
}
|
|
109
109
|
|
|
110
|
-
//
|
|
110
|
+
// packages/compiler-cli/src/ngtsc/file_system/src/helpers.js
|
|
111
111
|
var fs = new InvalidFileSystem();
|
|
112
112
|
function getFileSystem() {
|
|
113
113
|
return fs;
|
|
@@ -164,7 +164,7 @@ function toRelativeImport(relativePath) {
|
|
|
164
164
|
return isLocalRelativePath(relativePath) ? `./${relativePath}` : relativePath;
|
|
165
165
|
}
|
|
166
166
|
|
|
167
|
-
//
|
|
167
|
+
// packages/compiler-cli/src/ngtsc/file_system/src/compiler_host.js
|
|
168
168
|
import * as os from "os";
|
|
169
169
|
import ts from "typescript";
|
|
170
170
|
var NgtscCompilerHost = class {
|
|
@@ -224,8 +224,14 @@ var NgtscCompilerHost = class {
|
|
|
224
224
|
}
|
|
225
225
|
};
|
|
226
226
|
|
|
227
|
-
//
|
|
227
|
+
// packages/compiler-cli/src/ngtsc/file_system/src/logical.js
|
|
228
228
|
var LogicalProjectPath = {
|
|
229
|
+
/**
|
|
230
|
+
* Get the relative path between two `LogicalProjectPath`s.
|
|
231
|
+
*
|
|
232
|
+
* This will return a `PathSegment` which would be a valid module specifier to use in `from` when
|
|
233
|
+
* importing from `to`.
|
|
234
|
+
*/
|
|
229
235
|
relativePathBetween: function(from, to) {
|
|
230
236
|
const relativePath = relative(dirname(resolve(from)), resolve(to));
|
|
231
237
|
return toRelativeImport(relativePath);
|
|
@@ -233,17 +239,40 @@ var LogicalProjectPath = {
|
|
|
233
239
|
};
|
|
234
240
|
var LogicalFileSystem = class {
|
|
235
241
|
compilerHost;
|
|
242
|
+
/**
|
|
243
|
+
* The root directories of the project, sorted with the longest path first.
|
|
244
|
+
*/
|
|
236
245
|
rootDirs;
|
|
246
|
+
/**
|
|
247
|
+
* The same root directories as `rootDirs` but with each one converted to its
|
|
248
|
+
* canonical form for matching in case-insensitive file-systems.
|
|
249
|
+
*/
|
|
237
250
|
canonicalRootDirs;
|
|
251
|
+
/**
|
|
252
|
+
* A cache of file paths to project paths, because computation of these paths is slightly
|
|
253
|
+
* expensive.
|
|
254
|
+
*/
|
|
238
255
|
cache = /* @__PURE__ */ new Map();
|
|
239
256
|
constructor(rootDirs, compilerHost) {
|
|
240
257
|
this.compilerHost = compilerHost;
|
|
241
258
|
this.rootDirs = rootDirs.concat([]).sort((a, b) => b.length - a.length);
|
|
242
259
|
this.canonicalRootDirs = this.rootDirs.map((dir) => this.compilerHost.getCanonicalFileName(dir));
|
|
243
260
|
}
|
|
261
|
+
/**
|
|
262
|
+
* Get the logical path in the project of a `ts.SourceFile`.
|
|
263
|
+
*
|
|
264
|
+
* This method is provided as a convenient alternative to calling
|
|
265
|
+
* `logicalPathOfFile(absoluteFromSourceFile(sf))`.
|
|
266
|
+
*/
|
|
244
267
|
logicalPathOfSf(sf) {
|
|
245
268
|
return this.logicalPathOfFile(absoluteFromSourceFile(sf));
|
|
246
269
|
}
|
|
270
|
+
/**
|
|
271
|
+
* Get the logical path in the project of a source file.
|
|
272
|
+
*
|
|
273
|
+
* @returns A `LogicalProjectPath` to the source file, or `null` if the source file is not in any
|
|
274
|
+
* of the TS project's root directories.
|
|
275
|
+
*/
|
|
247
276
|
logicalPathOfFile(physicalFile) {
|
|
248
277
|
if (!this.cache.has(physicalFile)) {
|
|
249
278
|
const canonicalFilePath = this.compilerHost.getCanonicalFileName(physicalFile);
|
|
@@ -273,7 +302,7 @@ function isWithinBasePath(base, path) {
|
|
|
273
302
|
return isLocalRelativePath(relative(base, path));
|
|
274
303
|
}
|
|
275
304
|
|
|
276
|
-
//
|
|
305
|
+
// packages/compiler-cli/src/ngtsc/file_system/src/ts_read_directory.js
|
|
277
306
|
import ts2 from "typescript";
|
|
278
307
|
function createFileSystemTsReadDirectoryFn(fs2) {
|
|
279
308
|
if (ts2.matchFiles === void 0) {
|
|
@@ -335,4 +364,3 @@ export {
|
|
|
335
364
|
* Use of this source code is governed by an MIT-style license that can be
|
|
336
365
|
* found in the LICENSE file at https://angular.dev/license
|
|
337
366
|
*/
|
|
338
|
-
//# sourceMappingURL=chunk-TPEB2IXF.js.map
|