@ts-ioc-container/bundler 2.1.0 → 3.1.0
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/AGENTS.md +32 -22
- package/README.md +84 -84
- package/cjm/exceptions/DomainException.js +1 -7
- package/cjm/features/build/BuildConfig.js +48 -73
- package/cjm/features/build/domain/ImportPaths.js +13 -29
- package/cjm/features/build/domain/emit.js +2 -2
- package/cjm/features/build/domain/scan.js +0 -18
- package/cjm/features/build/domain/tokenCollisions.js +1 -1
- package/cjm/features/build/domain/tsconfig.js +16 -10
- package/cjm/features/build/services/BundleBuilder.js +8 -31
- package/cjm/index.js +2 -4
- package/cjm/schema/ticConfigSchema.js +1 -5
- package/package.json +2 -2
- package/tic.schema.json +85 -103
- package/tpl/index.cjs +19 -41
- package/typings/app.d.ts +1 -2
- package/typings/exceptions/DomainException.d.ts +0 -4
- package/typings/exceptions/DomainException.d.ts.map +1 -1
- package/typings/features/build/BuildConfig.d.ts +71 -82
- package/typings/features/build/BuildConfig.d.ts.map +1 -1
- package/typings/features/build/BuildController.d.ts +0 -1
- package/typings/features/build/BuildController.d.ts.map +1 -1
- package/typings/features/build/domain/ImportPaths.d.ts +13 -11
- package/typings/features/build/domain/ImportPaths.d.ts.map +1 -1
- package/typings/features/build/domain/emit.d.ts +1 -7
- package/typings/features/build/domain/emit.d.ts.map +1 -1
- package/typings/features/build/domain/scan.d.ts +0 -2
- package/typings/features/build/domain/scan.d.ts.map +1 -1
- package/typings/features/build/domain/tsconfig.d.ts +11 -15
- package/typings/features/build/domain/tsconfig.d.ts.map +1 -1
- package/typings/features/build/services/BundleBuilder.d.ts +5 -8
- package/typings/features/build/services/BundleBuilder.d.ts.map +1 -1
- package/typings/index.d.ts +4 -4
- package/typings/schema/ticConfigSchema.d.ts.map +1 -1
|
@@ -1,38 +1,10 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
/**
|
|
3
|
-
* Which files a bundle reads and parses: the first, cheap stage of selection,
|
|
4
|
-
* decided by path alone. The candidates are what the extended tsconfig compiles,
|
|
5
|
-
* or the folders in `paths` when given — they override the tsconfig's file set,
|
|
6
|
-
* as a child tsconfig's `include` overrides its parent's. A candidate is parsed
|
|
7
|
-
* when it matches one of `include` and none of `exclude`. Globs are relative to
|
|
8
|
-
* the config file and `/`-separated. With a file naming convention
|
|
9
|
-
* (`*.service.ts`), `include` keeps the bundler from reading anything else.
|
|
10
|
-
*/
|
|
11
|
-
export interface FileSelector {
|
|
12
|
-
/**
|
|
13
|
-
* Folders to scan instead of the tsconfig's file set: relative to the config file,
|
|
14
|
-
* or tsconfig `paths` aliases. Required when there is no tsconfig to extend.
|
|
15
|
-
*/
|
|
16
|
-
paths?: (string | PathConfig)[];
|
|
17
|
-
/** Globs a file must match one of, e.g. `**\/*.service.ts`. Default: every source file. */
|
|
18
|
-
include?: string[];
|
|
19
|
-
/** Globs of files never read. Replaces {@link DEFAULT_EXCLUDE} when given. */
|
|
20
|
-
exclude?: string[];
|
|
21
|
-
}
|
|
22
|
-
/** A {@link FileSelector} with its defaults filled in and its globs compiled. */
|
|
23
|
-
export interface ResolvedFileSelector {
|
|
24
|
-
/** `undefined`: the extended tsconfig's file set. */
|
|
25
|
-
paths?: Required<PathConfig>[];
|
|
26
|
-
include?: RegExp[];
|
|
27
|
-
exclude: RegExp[];
|
|
28
|
-
}
|
|
29
2
|
/** Which exports of a file count: both kinds, only named exports, or only the default export. */
|
|
30
3
|
export type ExportKind = 'any' | 'named' | 'default';
|
|
31
4
|
/**
|
|
32
|
-
* Which classes of a parsed file are registered
|
|
33
|
-
*
|
|
34
|
-
*
|
|
35
|
-
* rule selects every exported class.
|
|
5
|
+
* Which classes of a parsed file are registered. A class is selected when it is
|
|
6
|
+
* exported, not abstract, and meets every criterion set here; an empty rule
|
|
7
|
+
* selects every exported class.
|
|
36
8
|
*/
|
|
37
9
|
export interface ClassSelector {
|
|
38
10
|
/** Default `any`. */
|
|
@@ -60,22 +32,31 @@ export interface ResolvedClassSelector {
|
|
|
60
32
|
excludeClasses?: string[];
|
|
61
33
|
excludeName?: RegExp;
|
|
62
34
|
}
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
35
|
+
/**
|
|
36
|
+
* `compilerOptions` of a bundle config: the tsconfig's own options plus the bundler's.
|
|
37
|
+
* `importExtension` and `classes` are read by `tic build`; every other option (`paths`,
|
|
38
|
+
* `baseUrl`, `rootDir`, `moduleResolution`, ...) is handed to TypeScript on top of the
|
|
39
|
+
* extended tsconfig, exactly as a child tsconfig's would be.
|
|
40
|
+
*/
|
|
41
|
+
export interface BundleCompilerOptions {
|
|
42
|
+
/** Extension of generated imports. Inferred from the tsconfig's `moduleResolution` when omitted. */
|
|
43
|
+
importExtension?: string;
|
|
44
|
+
/** Which classes of a scanned file are registered. Default: every exported class decorated with `@register`. */
|
|
45
|
+
classes?: ClassSelector;
|
|
46
|
+
[option: string]: unknown;
|
|
68
47
|
}
|
|
69
48
|
/**
|
|
70
|
-
* The shape of `*.bundle.json`: one bundle,
|
|
71
|
-
*
|
|
49
|
+
* The shape of `*.bundle.json`: one bundle, written as a tsconfig. `extends`, `include`,
|
|
50
|
+
* `exclude` and `compilerOptions` mean what they mean in a tsconfig, so the files the bundle
|
|
51
|
+
* scans are the files this config would compile; `output`, `name` and the bundler's
|
|
52
|
+
* own compiler options describe the generated module. A project that needs several bundles
|
|
53
|
+
* keeps one config file per bundle.
|
|
72
54
|
*/
|
|
73
55
|
export interface BundleConfig {
|
|
74
56
|
$schema?: string;
|
|
75
57
|
/**
|
|
76
58
|
* The generated file, relative to the config file. Default `<root>/<name>.bundle.ts`:
|
|
77
|
-
* `<root>` is the
|
|
78
|
-
* Required when there is no tsconfig to extend.
|
|
59
|
+
* `<root>` is the compiled `rootDir`, else the common folder of the files compiled.
|
|
79
60
|
*/
|
|
80
61
|
output?: string;
|
|
81
62
|
/**
|
|
@@ -85,81 +66,88 @@ export interface BundleConfig {
|
|
|
85
66
|
* an `IContainerModule` (`ProductionBundle`, see {@link toClassName}).
|
|
86
67
|
*/
|
|
87
68
|
name?: string;
|
|
88
|
-
/** Tags associated with the bundle. */
|
|
89
|
-
tags?: string[];
|
|
90
69
|
/**
|
|
91
|
-
* The tsconfig
|
|
92
|
-
*
|
|
93
|
-
* Default `./tsconfig.json`, which may be absent; a tsconfig named here must exist.
|
|
70
|
+
* The tsconfig this config extends, as a tsconfig's own `extends`. Relative to the config
|
|
71
|
+
* file. Default `./tsconfig.json`, which may be absent; a tsconfig named here must exist.
|
|
94
72
|
*/
|
|
95
73
|
extends?: string;
|
|
96
|
-
/**
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
74
|
+
/**
|
|
75
|
+
* The base folder this config's relative `include`, `exclude` and `output` resolve against,
|
|
76
|
+
* so they need not repeat a shared prefix such as `src`. Relative to the config file; default
|
|
77
|
+
* the config file's directory. It is also handed to TypeScript as `compilerOptions.baseUrl`
|
|
78
|
+
* (unless that is set too), so the generated imports use it as well.
|
|
79
|
+
*/
|
|
80
|
+
baseUrl?: string;
|
|
81
|
+
/** tsconfig `include`: replaces the extended tsconfig's. Relative to `baseUrl`. */
|
|
82
|
+
include?: string[];
|
|
83
|
+
/** tsconfig `exclude`: replaces the extended tsconfig's. Relative to `baseUrl`. {@link DEFAULT_EXCLUDE} applies regardless. */
|
|
84
|
+
exclude?: string[];
|
|
85
|
+
compilerOptions?: BundleCompilerOptions;
|
|
102
86
|
}
|
|
103
87
|
export declare const DEFAULT_EXTENDS = "./tsconfig.json";
|
|
104
88
|
/** The bundle name when the config file gives none, e.g. building from `tsconfig.json` alone. */
|
|
105
89
|
export declare const DEFAULT_BUNDLE_NAME = "base";
|
|
106
90
|
/** What `classes.decorators` requires when omitted: the library's own `@register`. */
|
|
107
91
|
export declare const DEFAULT_DECORATORS: string[];
|
|
92
|
+
/** Files never scanned, whatever the tsconfig compiles: tests, and anything under `node_modules`. */
|
|
108
93
|
export declare const DEFAULT_EXCLUDE: string[];
|
|
94
|
+
/** The tsconfig part of a bundle config, handed to TypeScript as a tsconfig of its own. */
|
|
95
|
+
export interface TsconfigOverrides {
|
|
96
|
+
include?: string[];
|
|
97
|
+
exclude?: string[];
|
|
98
|
+
/** `compilerOptions` without the bundler's own options. */
|
|
99
|
+
compilerOptions: Record<string, unknown>;
|
|
100
|
+
}
|
|
109
101
|
/** A {@link BundleConfig} whose defaults are filled in and whose paths are absolute. */
|
|
110
102
|
export interface ResolvedConfig {
|
|
111
103
|
/** The config file itself. */
|
|
112
104
|
file: string;
|
|
113
105
|
dir: string;
|
|
114
|
-
/** `undefined`: derived from
|
|
106
|
+
/** `undefined`: derived from what is compiled at build time (see {@link BundleConfig.output}). */
|
|
115
107
|
output?: string;
|
|
116
108
|
/** The bundle name: `production` for `production.bundle.json`. */
|
|
117
109
|
name: string;
|
|
118
110
|
/** The generated class: `ProductionBundle`. */
|
|
119
111
|
className: string;
|
|
120
|
-
tags: string[];
|
|
121
112
|
/** The extended tsconfig; `required` when the config names it, so it must exist. */
|
|
122
113
|
tsconfig: {
|
|
123
114
|
file: string;
|
|
124
115
|
required: boolean;
|
|
125
116
|
};
|
|
117
|
+
/** What the config sets on top of {@link tsconfig}. */
|
|
118
|
+
overrides: TsconfigOverrides;
|
|
126
119
|
importExtension?: string;
|
|
127
|
-
files: ResolvedFileSelector;
|
|
128
120
|
classes: ResolvedClassSelector;
|
|
129
|
-
/** Non-fatal problems found while resolving, e.g. a `files.exclude` that drops a default test glob. */
|
|
130
|
-
warnings: string[];
|
|
131
121
|
}
|
|
132
122
|
/**
|
|
133
|
-
* One `*.bundle.json` / `*.bundle.yaml
|
|
134
|
-
* from it (`ticConfigJsonSchema`), so the schema editors
|
|
135
|
-
* from what `tic build` accepts.
|
|
123
|
+
* One `*.bundle.json` / `*.bundle.yaml`: a tsconfig with the bundler's fields. The published
|
|
124
|
+
* `tic.schema.json` is generated from it (`ticConfigJsonSchema`), so the schema editors
|
|
125
|
+
* validate against cannot drift from what `tic build` accepts.
|
|
136
126
|
*/
|
|
137
127
|
export declare const BUNDLE_CONFIG_SCHEMA: z.ZodObject<{
|
|
138
128
|
$schema: z.ZodOptional<z.ZodString>;
|
|
129
|
+
extends: z.ZodOptional<z.ZodString>;
|
|
130
|
+
baseUrl: z.ZodOptional<z.ZodString>;
|
|
139
131
|
output: z.ZodOptional<z.ZodString>;
|
|
140
132
|
name: z.ZodOptional<z.ZodString>;
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
name: z.ZodOptional<z.ZodString>;
|
|
160
|
-
excludeClasses: z.ZodOptional<z.ZodCustom<string[], string[]>>;
|
|
161
|
-
excludeName: z.ZodOptional<z.ZodString>;
|
|
162
|
-
}, z.core.$strict>>;
|
|
133
|
+
include: z.ZodOptional<z.ZodCustom<string[], string[]>>;
|
|
134
|
+
exclude: z.ZodOptional<z.ZodCustom<string[], string[]>>;
|
|
135
|
+
compilerOptions: z.ZodOptional<z.ZodObject<{
|
|
136
|
+
importExtension: z.ZodOptional<z.ZodString>;
|
|
137
|
+
classes: z.ZodOptional<z.ZodObject<{
|
|
138
|
+
export: z.ZodDefault<z.ZodEnum<{
|
|
139
|
+
default: "default";
|
|
140
|
+
any: "any";
|
|
141
|
+
named: "named";
|
|
142
|
+
}>>;
|
|
143
|
+
decorators: z.ZodDefault<z.ZodCustom<string[], string[]>>;
|
|
144
|
+
name: z.ZodOptional<z.ZodString>;
|
|
145
|
+
excludeClasses: z.ZodOptional<z.ZodCustom<string[], string[]>>;
|
|
146
|
+
excludeName: z.ZodOptional<z.ZodString>;
|
|
147
|
+
}, z.core.$strict>>;
|
|
148
|
+
paths: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString>>>;
|
|
149
|
+
rootDir: z.ZodOptional<z.ZodString>;
|
|
150
|
+
}, z.core.$loose>>;
|
|
163
151
|
}, z.core.$strict>;
|
|
164
152
|
/**
|
|
165
153
|
* A config file is named `<name>.bundle.json`, `<name>.bundle.yaml` or `<name>.bundle.yml`,
|
|
@@ -171,7 +159,8 @@ export declare const configSuffix: (file: string) => string | undefined;
|
|
|
171
159
|
/** The generated class for a bundle name: `production` -> `ProductionBundle`, `my-app_v2` -> `MyAppV2Bundle`. */
|
|
172
160
|
export declare function toClassName(name: string): string;
|
|
173
161
|
/**
|
|
174
|
-
* Validates parsed `*.bundle.json` content and resolves its paths against `file`'s
|
|
162
|
+
* Validates parsed `*.bundle.json` content and resolves its paths against `file`'s
|
|
163
|
+
* directory, or its `baseUrl` for `include` / `exclude` / `output`.
|
|
175
164
|
*
|
|
176
165
|
* @throws {TicConfigError} when the content does not match the config shape; the message names the field.
|
|
177
166
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BuildConfig.d.ts","sourceRoot":"","sources":["../../../lib/features/build/BuildConfig.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB
|
|
1
|
+
{"version":3,"file":"BuildConfig.d.ts","sourceRoot":"","sources":["../../../lib/features/build/BuildConfig.ts"],"names":[],"mappings":"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"}
|
|
@@ -24,7 +24,6 @@ export declare class BuildController {
|
|
|
24
24
|
*
|
|
25
25
|
* @throws {UsageError} when an option is unknown or `--config` has no value.
|
|
26
26
|
* @throws {TicConfigError} when a config or its tsconfig is missing or invalid, or none can be found.
|
|
27
|
-
* @throws {NamespaceNotFoundError} when a path is neither a folder nor a tsconfig paths alias of one.
|
|
28
27
|
* @throws {StaleBundlesError} when `--check` finds a bundle that differs from what a build would write.
|
|
29
28
|
*/
|
|
30
29
|
build(options: BuildCliOptions): void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BuildController.d.ts","sourceRoot":"","sources":["../../../lib/features/build/BuildController.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,OAAO,EAAE,KAAK,OAAO,EAAc,MAAM,8BAA8B,CAAC;AACxE,OAAO,EAAE,KAAK,cAAc,EAAqB,MAAM,8BAA8B,CAAC;AACtF,OAAO,EAAE,KAAK,cAAc,EAAwC,MAAM,0BAA0B,CAAC;AACrG,OAAO,EAAE,KAAK,iBAAiB,EAAuC,MAAM,6BAA6B,CAAC;AAE1G,eAAO,MAAM,aAAa;;;iBAGxB,CAAC;AAEH,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,MAAM,CAAC,OAAO,aAAa,CAAC,CAAC;AAW7D,kDAAkD;AAClD,qBACa,eAAe;IAEK,OAAO,CAAC,QAAQ,CAAC,GAAG;IACf,OAAO,CAAC,QAAQ,CAAC,OAAO;IAC3B,OAAO,CAAC,QAAQ,CAAC,OAAO;IACxB,OAAO,CAAC,QAAQ,CAAC,MAAM;IAC9B,OAAO,CAAC,QAAQ,CAAC,MAAM;gBAJD,GAAG,EAAE,MAAM,EACN,OAAO,EAAE,iBAAiB,EAC7B,OAAO,EAAE,cAAc,EACvB,MAAM,EAAE,cAAc,EAC7B,MAAM,EAAE,OAAO;IAG1D
|
|
1
|
+
{"version":3,"file":"BuildController.d.ts","sourceRoot":"","sources":["../../../lib/features/build/BuildController.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,OAAO,EAAE,KAAK,OAAO,EAAc,MAAM,8BAA8B,CAAC;AACxE,OAAO,EAAE,KAAK,cAAc,EAAqB,MAAM,8BAA8B,CAAC;AACtF,OAAO,EAAE,KAAK,cAAc,EAAwC,MAAM,0BAA0B,CAAC;AACrG,OAAO,EAAE,KAAK,iBAAiB,EAAuC,MAAM,6BAA6B,CAAC;AAE1G,eAAO,MAAM,aAAa;;;iBAGxB,CAAC;AAEH,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,MAAM,CAAC,OAAO,aAAa,CAAC,CAAC;AAW7D,kDAAkD;AAClD,qBACa,eAAe;IAEK,OAAO,CAAC,QAAQ,CAAC,GAAG;IACf,OAAO,CAAC,QAAQ,CAAC,OAAO;IAC3B,OAAO,CAAC,QAAQ,CAAC,OAAO;IACxB,OAAO,CAAC,QAAQ,CAAC,MAAM;IAC9B,OAAO,CAAC,QAAQ,CAAC,MAAM;gBAJD,GAAG,EAAE,MAAM,EACN,OAAO,EAAE,iBAAiB,EAC7B,OAAO,EAAE,cAAc,EACvB,MAAM,EAAE,cAAc,EAC7B,MAAM,EAAE,OAAO;IAG1D;;;;;;;;;OASG;IAEH,KAAK,CAAgE,OAAO,EAAE,eAAe,GAAG,IAAI;CAiBrG"}
|
|
@@ -5,28 +5,30 @@ interface Alias {
|
|
|
5
5
|
targets: string[];
|
|
6
6
|
}
|
|
7
7
|
/**
|
|
8
|
-
* Import paths as a project's `tsconfig.json` sees them:
|
|
9
|
-
*
|
|
8
|
+
* Import paths as a project's `tsconfig.json` sees them: writes imports in the
|
|
9
|
+
* form of its `paths` aliases, else its `baseUrl`, where one matches.
|
|
10
10
|
*/
|
|
11
11
|
export declare class ImportPaths {
|
|
12
12
|
private readonly aliases;
|
|
13
13
|
readonly extension: string;
|
|
14
|
+
/** Absolute, `/`-separated: non-relative imports resolve against it. */
|
|
15
|
+
private readonly baseUrl?;
|
|
14
16
|
/**
|
|
15
|
-
* From a parsed tsconfig's options: its `paths` aliases
|
|
16
|
-
* under its `moduleResolution`; `importExtension` overrides the latter.
|
|
17
|
+
* From a parsed tsconfig's options: its `paths` aliases and `baseUrl`, and the extension
|
|
18
|
+
* imports need under its `moduleResolution`; `importExtension` overrides the latter.
|
|
17
19
|
*/
|
|
18
20
|
static fromOptions(options: ts.CompilerOptions, tsconfigFile: string, importExtension?: string): ImportPaths;
|
|
19
|
-
constructor(aliases: Alias[], extension: string
|
|
21
|
+
constructor(aliases: Alias[], extension: string,
|
|
22
|
+
/** Absolute, `/`-separated: non-relative imports resolve against it. */
|
|
23
|
+
baseUrl?: string | undefined);
|
|
20
24
|
/**
|
|
21
|
-
* The
|
|
22
|
-
*
|
|
23
|
-
* @throws {NamespaceNotFoundError} when the namespace is neither an existing folder nor an alias of one.
|
|
25
|
+
* The specifier `fromFile` imports `toFile` by: its most specific `paths` alias, else a
|
|
26
|
+
* path relative to `baseUrl` when the file is under it, else a path relative to `fromFile`.
|
|
24
27
|
*/
|
|
25
|
-
resolveNamespace(namespace: string, baseDir: string): string;
|
|
26
|
-
/** The specifier `fromFile` imports `toFile` by: its most specific alias, else a relative path. */
|
|
27
28
|
specifier(fromFile: string, toFile: string): string;
|
|
29
|
+
/** `bare` written relative to `baseUrl`, when it is under it; `undefined` otherwise. */
|
|
30
|
+
private baseUrlSpecifier;
|
|
28
31
|
private bestAlias;
|
|
29
|
-
private aliasTargets;
|
|
30
32
|
/** A longer matched target prefix is a more specific alias; an exact file alias beats every wildcard. */
|
|
31
33
|
private matchAlias;
|
|
32
34
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ImportPaths.d.ts","sourceRoot":"","sources":["../../../../lib/features/build/domain/ImportPaths.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ImportPaths.d.ts","sourceRoot":"","sources":["../../../../lib/features/build/domain/ImportPaths.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,YAAY,CAAC;AAGjC,UAAU,KAAK;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,+BAA+B;IAC/B,OAAO,EAAE,MAAM,EAAE,CAAC;CACnB;AAUD;;;GAGG;AACH,qBAAa,WAAW;IAuBpB,OAAO,CAAC,QAAQ,CAAC,OAAO;IACxB,QAAQ,CAAC,SAAS,EAAE,MAAM;IAC1B,wEAAwE;IACxE,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAC;IAzB3B;;;OAGG;IACH,MAAM,CAAC,WAAW,CAAC,OAAO,EAAE,EAAE,CAAC,eAAe,EAAE,YAAY,EAAE,MAAM,EAAE,eAAe,CAAC,EAAE,MAAM,GAAG,WAAW;gBAkBzF,OAAO,EAAE,KAAK,EAAE,EACxB,SAAS,EAAE,MAAM;IAC1B,wEAAwE;IACvD,OAAO,CAAC,EAAE,MAAM,YAAA;IAGnC;;;OAGG;IACH,SAAS,CAAC,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,MAAM;IAanD,wFAAwF;IACxF,OAAO,CAAC,gBAAgB;IAMxB,OAAO,CAAC,SAAS;IAWjB,yGAAyG;IACzG,OAAO,CAAC,UAAU;CAanB"}
|
|
@@ -4,10 +4,6 @@ export interface EmitInput {
|
|
|
4
4
|
name: string;
|
|
5
5
|
/** Shown in the header: where the output came from. */
|
|
6
6
|
configPath: string;
|
|
7
|
-
/** The folders scanned; `undefined` when the files came from the extended tsconfig. */
|
|
8
|
-
paths?: string[];
|
|
9
|
-
/** Shown in the header when `paths` is `undefined`: the tsconfig the files came from. */
|
|
10
|
-
tsconfigPath: string;
|
|
11
7
|
classes: (DiscoveredClass & {
|
|
12
8
|
specifier: string;
|
|
13
9
|
})[];
|
|
@@ -17,8 +13,6 @@ export declare const GENERATED_HEADER = "// Generated by `tic build`";
|
|
|
17
13
|
/** What `protocols/Bundle.ts.hbs` renders. */
|
|
18
14
|
export interface BundleView {
|
|
19
15
|
configPath: string;
|
|
20
|
-
paths?: string[];
|
|
21
|
-
tsconfigPath: string;
|
|
22
16
|
name: string;
|
|
23
17
|
imports: {
|
|
24
18
|
specifier: string;
|
|
@@ -33,7 +27,7 @@ export declare const BUNDLE_PROTOCOL = "Bundle.ts.hbs";
|
|
|
33
27
|
* Prepares the data the bundle protocol renders: unique local names, and one import
|
|
34
28
|
* per file in file order.
|
|
35
29
|
*/
|
|
36
|
-
export declare function bundleView({ name, configPath,
|
|
30
|
+
export declare function bundleView({ name, configPath, classes }: EmitInput): BundleView;
|
|
37
31
|
/**
|
|
38
32
|
* Renders the generated bundle — static imports, `registrations`, and the bundle applying them —
|
|
39
33
|
* from its protocol, `protocols/Bundle.ts.hbs`.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"emit.d.ts","sourceRoot":"","sources":["../../../../lib/features/build/domain/emit.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,QAAQ,CAAC;AAE9C,MAAM,WAAW,SAAS;IACxB,mCAAmC;IACnC,IAAI,EAAE,MAAM,CAAC;IACb,uDAAuD;IACvD,UAAU,EAAE,MAAM,CAAC;IACnB,
|
|
1
|
+
{"version":3,"file":"emit.d.ts","sourceRoot":"","sources":["../../../../lib/features/build/domain/emit.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,QAAQ,CAAC;AAE9C,MAAM,WAAW,SAAS;IACxB,mCAAmC;IACnC,IAAI,EAAE,MAAM,CAAC;IACb,uDAAuD;IACvD,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,CAAC,eAAe,GAAG;QAAE,SAAS,EAAE,MAAM,CAAA;KAAE,CAAC,EAAE,CAAC;CACtD;AAED,iFAAiF;AACjF,eAAO,MAAM,gBAAgB,gCAAgC,CAAC;AAE9D,8CAA8C;AAC9C,MAAM,WAAW,UAAU;IACzB,UAAU,EAAE,MAAM,CAAC;IACnB,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE;QAAE,SAAS,EAAE,MAAM,CAAC;QAAC,WAAW,CAAC,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,EAAE,CAAA;KAAE,EAAE,CAAC;IACxE,aAAa,EAAE,MAAM,EAAE,CAAC;CACzB;AAED,8CAA8C;AAC9C,eAAO,MAAM,eAAe,kBAAkB,CAAC;AAI/C;;;GAGG;AACH,wBAAgB,UAAU,CAAC,EAAE,IAAI,EAAE,UAAU,EAAE,OAAO,EAAE,EAAE,SAAS,GAAG,UAAU,CAqB/E;AAED;;;GAGG;AACH,wBAAgB,UAAU,CAAC,KAAK,EAAE,SAAS,GAAG,MAAM,CAEnD"}
|
|
@@ -29,8 +29,6 @@ export interface DiscoveredClass {
|
|
|
29
29
|
}
|
|
30
30
|
/** A TypeScript source file the bundler may parse: not a declaration file. */
|
|
31
31
|
export declare const isSourceFile: (file: string) => boolean;
|
|
32
|
-
/** Source files of `dir`, sorted by path so the generated output is stable across machines. */
|
|
33
|
-
export declare function listSourceFiles(dir: string, recursive: boolean, isExcluded: (file: string) => boolean): string[];
|
|
34
32
|
/**
|
|
35
33
|
* The exported, non-abstract classes of one file that `selector` selects, in
|
|
36
34
|
* declaration order. Syntax only: decorators are recognised by name, not by type.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"scan.d.ts","sourceRoot":"","sources":["../../../../lib/features/build/domain/scan.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,gBAAgB,CAAC;AAE5D,wDAAwD;AACxD,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,MAAM,CAAC;IACb,qEAAqE;IACrE,UAAU,EAAE,MAAM,CAAC;IACnB,yEAAyE;IACzE,SAAS,EAAE,MAAM,CAAC;IAClB,oFAAoF;IACpF,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,OAAO,CAAC;IACnB,iEAAiE;IACjE,UAAU,EAAE,MAAM,EAAE,CAAC;IACrB;;;;OAIG;IACH,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB;;;;OAIG;IACH,cAAc,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,EAAE,CAAA;KAAE,EAAE,CAAC;CACpD;AAKD,8EAA8E;AAC9E,eAAO,MAAM,YAAY,GAAI,MAAM,MAAM,KAAG,OAAiE,CAAC;
|
|
1
|
+
{"version":3,"file":"scan.d.ts","sourceRoot":"","sources":["../../../../lib/features/build/domain/scan.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,gBAAgB,CAAC;AAE5D,wDAAwD;AACxD,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,MAAM,CAAC;IACb,qEAAqE;IACrE,UAAU,EAAE,MAAM,CAAC;IACnB,yEAAyE;IACzE,SAAS,EAAE,MAAM,CAAC;IAClB,oFAAoF;IACpF,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,OAAO,CAAC;IACnB,iEAAiE;IACjE,UAAU,EAAE,MAAM,EAAE,CAAC;IACrB;;;;OAIG;IACH,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB;;;;OAIG;IACH,cAAc,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,EAAE,CAAA;KAAE,EAAE,CAAC;CACpD;AAKD,8EAA8E;AAC9E,eAAO,MAAM,YAAY,GAAI,MAAM,MAAM,KAAG,OAAiE,CAAC;AA2B9G;;;GAGG;AACH,wBAAgB,WAAW,CACzB,IAAI,EAAE,MAAM,EACZ,QAAQ,EAAE,qBAAqB,EAC/B,IAAI,SAA6B,GAChC,eAAe,EAAE,CAmFnB"}
|
|
@@ -1,25 +1,21 @@
|
|
|
1
|
+
import type { ResolvedConfig } from '../BuildConfig.js';
|
|
1
2
|
import { ImportPaths } from './ImportPaths.js';
|
|
2
|
-
/** What a bundle
|
|
3
|
-
export interface
|
|
3
|
+
/** What a bundle compiles: the bundle config read as a tsconfig, on top of the tsconfig it extends. */
|
|
4
|
+
export interface CompiledTsconfig {
|
|
4
5
|
importPaths: ImportPaths;
|
|
5
|
-
/** Absolute paths of the files
|
|
6
|
-
fileNames
|
|
6
|
+
/** Absolute paths of the files compiled. */
|
|
7
|
+
fileNames: string[];
|
|
7
8
|
/**
|
|
8
9
|
* Where the sources live, as tsc sees it: `rootDir`, else the longest common folder of
|
|
9
|
-
* the non-declaration files
|
|
10
|
-
* there is no tsconfig.
|
|
10
|
+
* the non-declaration files compiled, else the config's folder.
|
|
11
11
|
*/
|
|
12
|
-
rootDir
|
|
12
|
+
rootDir: string;
|
|
13
13
|
}
|
|
14
14
|
/**
|
|
15
|
-
*
|
|
16
|
-
*
|
|
17
|
-
* was not named explicitly yields no aliases and no file set.
|
|
15
|
+
* Compiles a bundle config as a tsconfig, following `extends`: the files it compiles
|
|
16
|
+
* (`include` / `exclude`, as overridden), its `paths` aliases and import extension.
|
|
18
17
|
*
|
|
19
|
-
* @throws {TicConfigError} when a required tsconfig is missing or
|
|
18
|
+
* @throws {TicConfigError} when a required tsconfig is missing, or the config or a tsconfig it extends is invalid.
|
|
20
19
|
*/
|
|
21
|
-
export declare function loadTsconfig(
|
|
22
|
-
file: string;
|
|
23
|
-
required: boolean;
|
|
24
|
-
}, importExtension?: string): ExtendedTsconfig;
|
|
20
|
+
export declare function loadTsconfig(config: ResolvedConfig): CompiledTsconfig;
|
|
25
21
|
//# sourceMappingURL=tsconfig.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tsconfig.d.ts","sourceRoot":"","sources":["../../../../lib/features/build/domain/tsconfig.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAM5C,
|
|
1
|
+
{"version":3,"file":"tsconfig.d.ts","sourceRoot":"","sources":["../../../../lib/features/build/domain/tsconfig.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AACrD,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAM5C,uGAAuG;AACvG,MAAM,WAAW,gBAAgB;IAC/B,WAAW,EAAE,WAAW,CAAC;IACzB,4CAA4C;IAC5C,SAAS,EAAE,MAAM,EAAE,CAAC;IACpB;;;OAGG;IACH,OAAO,EAAE,MAAM,CAAC;CACjB;AA+BD;;;;;GAKG;AACH,wBAAgB,YAAY,CAAC,MAAM,EAAE,cAAc,GAAG,gBAAgB,CAerE"}
|
|
@@ -33,8 +33,8 @@ export interface BuildResult {
|
|
|
33
33
|
config: string;
|
|
34
34
|
output: OutputResult;
|
|
35
35
|
/**
|
|
36
|
-
* Non-fatal problems found while building, e.g.
|
|
37
|
-
*
|
|
36
|
+
* Non-fatal problems found while building, e.g. two selected classes passing the same
|
|
37
|
+
* decorator token.
|
|
38
38
|
*/
|
|
39
39
|
warnings: string[];
|
|
40
40
|
}
|
|
@@ -42,8 +42,7 @@ export interface IBundleBuilder {
|
|
|
42
42
|
/**
|
|
43
43
|
* Generates the bundle a config describes. Nothing is written unless generation succeeds.
|
|
44
44
|
*
|
|
45
|
-
* @throws {TicConfigError} when the config or
|
|
46
|
-
* @throws {NamespaceNotFoundError} when a path is neither a folder nor a tsconfig paths alias of one.
|
|
45
|
+
* @throws {TicConfigError} when the config or the tsconfig it extends is missing or invalid.
|
|
47
46
|
*/
|
|
48
47
|
build(request?: BuildRequest): BuildResult;
|
|
49
48
|
}
|
|
@@ -55,13 +54,11 @@ export declare class BundleBuilder implements IBundleBuilder {
|
|
|
55
54
|
private readonly renderer;
|
|
56
55
|
constructor(cwd: string, configs: ITicConfigService, fs: IFileSystemService, renderer: IRenderService);
|
|
57
56
|
/**
|
|
58
|
-
* @throws {TicConfigError} when the config or
|
|
59
|
-
* @throws {NamespaceNotFoundError} when a path is neither a folder nor a tsconfig paths alias of one.
|
|
57
|
+
* @throws {TicConfigError} when the config or the tsconfig it extends is missing or invalid.
|
|
60
58
|
*/
|
|
61
59
|
build({ config, check }?: BuildRequest): BuildResult;
|
|
62
60
|
/**
|
|
63
|
-
* @throws {TicConfigError} when the
|
|
64
|
-
* @throws {NamespaceNotFoundError} when a path is neither a folder nor a tsconfig paths alias of one.
|
|
61
|
+
* @throws {TicConfigError} when the config or the tsconfig it extends is missing or invalid.
|
|
65
62
|
*/
|
|
66
63
|
private generate;
|
|
67
64
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BundleBuilder.d.ts","sourceRoot":"","sources":["../../../../lib/features/build/services/BundleBuilder.ts"],"names":[],"mappings":"AACA,OAAO,EAAwB,WAAW,EAAE,MAAM,kBAAkB,CAAC;
|
|
1
|
+
{"version":3,"file":"BundleBuilder.d.ts","sourceRoot":"","sources":["../../../../lib/features/build/services/BundleBuilder.ts"],"names":[],"mappings":"AACA,OAAO,EAAwB,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAErE,OAAO,EAAE,KAAK,cAAc,EAAqB,MAAM,2CAA2C,CAAC;AACnG,OAAO,EAAE,KAAK,kBAAkB,EAAyB,MAAM,yCAAyC,CAAC;AAQzG,OAAO,EAAE,KAAK,iBAAiB,EAAuC,MAAM,oBAAoB,CAAC;AAIjG,8EAA8E;AAC9E,MAAM,WAAW,YAAY;IAC3B;;;;OAIG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,kFAAkF;IAClF,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB;AAED,MAAM,WAAW,YAAa,SAAQ,YAAY;IAChD,+BAA+B;IAC/B,GAAG,CAAC,EAAE,MAAM,CAAC;CACd;AAED,kFAAkF;AAClF,MAAM,MAAM,YAAY,GAAG,SAAS,GAAG,WAAW,GAAG,OAAO,CAAC;AAE7D,MAAM,WAAW,YAAY;IAC3B,2CAA2C;IAC3C,IAAI,EAAE,MAAM,CAAC;IACb,mCAAmC;IACnC,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,YAAY,CAAC;IACrB,aAAa,EAAE,MAAM,CAAC;IACtB,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,WAAW;IAC1B,kDAAkD;IAClD,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,YAAY,CAAC;IACrB;;;OAGG;IACH,QAAQ,EAAE,MAAM,EAAE,CAAC;CACpB;AAED,MAAM,WAAW,cAAc;IAC7B;;;;OAIG;IACH,KAAK,CAAC,OAAO,CAAC,EAAE,YAAY,GAAG,WAAW,CAAC;CAC5C;AAED,eAAO,MAAM,iBAAiB,6BAAoD,CAAC;AAEnF,qBACa,aAAc,YAAW,cAAc;IAEnB,OAAO,CAAC,QAAQ,CAAC,GAAG;IACf,OAAO,CAAC,QAAQ,CAAC,OAAO;IACvB,OAAO,CAAC,QAAQ,CAAC,EAAE;IACvB,OAAO,CAAC,QAAQ,CAAC,QAAQ;gBAHV,GAAG,EAAE,MAAM,EACN,OAAO,EAAE,iBAAiB,EACzB,EAAE,EAAE,kBAAkB,EAC1B,QAAQ,EAAE,cAAc;IAG1E;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,EAAE,KAAa,EAAE,GAAE,YAAiB,GAAG,WAAW;IAiBhE;;OAEG;IACH,OAAO,CAAC,QAAQ;CA8BjB"}
|
package/typings/index.d.ts
CHANGED
|
@@ -6,12 +6,12 @@ export { BuildModule } from './features/build/BuildModule.js';
|
|
|
6
6
|
export { BuildController, BUILD_OPTIONS, type BuildCliOptions } from './features/build/BuildController.js';
|
|
7
7
|
export { BundleBuilder, IBundleBuilderKey, type IBundleBuilder, type BuildRequest, type BuildOptions, type BuildResult, type OutputResult, type OutputStatus, } from './features/build/services/BundleBuilder.js';
|
|
8
8
|
export { TicConfigService, ITicConfigServiceKey, TSCONFIG_FILE, type ITicConfigService, } from './features/build/services/TicConfigService.js';
|
|
9
|
-
export { resolveConfig, BUNDLE_CONFIG_SCHEMA, CONFIG_FILE_SUFFIXES, DEFAULT_EXTENDS, DEFAULT_EXCLUDE, DEFAULT_BUNDLE_NAME, DEFAULT_DECORATORS, toClassName, type BundleConfig, type
|
|
9
|
+
export { resolveConfig, BUNDLE_CONFIG_SCHEMA, CONFIG_FILE_SUFFIXES, DEFAULT_EXTENDS, DEFAULT_EXCLUDE, DEFAULT_BUNDLE_NAME, DEFAULT_DECORATORS, toClassName, type BundleConfig, type BundleCompilerOptions, type ClassSelector, type ExportKind, type ResolvedClassSelector, type ResolvedConfig, type TsconfigOverrides, } from './features/build/BuildConfig.js';
|
|
10
10
|
export { findConfigFiles, findPackageRoot } from './features/build/domain/configFiles.js';
|
|
11
11
|
export { ticConfigJsonSchema } from './schema/ticConfigSchema.js';
|
|
12
12
|
export { ImportPaths } from './features/build/domain/ImportPaths.js';
|
|
13
|
-
export { loadTsconfig, type
|
|
14
|
-
export { findClasses, isSourceFile,
|
|
13
|
+
export { loadTsconfig, type CompiledTsconfig } from './features/build/domain/tsconfig.js';
|
|
14
|
+
export { findClasses, isSourceFile, type DiscoveredClass } from './features/build/domain/scan.js';
|
|
15
15
|
export { emitBundle, bundleView, BUNDLE_PROTOCOL, GENERATED_HEADER, type EmitInput, type BundleView, } from './features/build/domain/emit.js';
|
|
16
16
|
export { tokenCollisions } from './features/build/domain/tokenCollisions.js';
|
|
17
17
|
export { globToRegExp } from './features/build/domain/glob.js';
|
|
@@ -21,6 +21,6 @@ export { type IOutputService, IOutputServiceKey, StdOutputService } from './serv
|
|
|
21
21
|
export { type ILogger, ILoggerKey, ConsoleLogger } from './services/ConsoleLogger.js';
|
|
22
22
|
export { type IFileSystemService, IFileSystemServiceKey, NodeFileSystemService, } from './services/NodeFileSystemService.js';
|
|
23
23
|
export { type IRenderService, IRenderServiceKey, HandlebarsRenderService, renderProtocol, } from './services/HandlebarsRenderService.js';
|
|
24
|
-
export { TicError, TicConfigError,
|
|
24
|
+
export { TicError, TicConfigError, MissingCommandError, UnknownCommandError, UnknownActionError, UsageError, StaleBundlesError, } from './exceptions/DomainException.js';
|
|
25
25
|
export { ExceptionHandler } from './exceptions/ExceptionHandler.js';
|
|
26
26
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ticConfigSchema.d.ts","sourceRoot":"","sources":["../../lib/schema/ticConfigSchema.ts"],"names":[],"mappings":"AAGA;;;;GAIG;AACH,wBAAgB,mBAAmB,IAAI,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,
|
|
1
|
+
{"version":3,"file":"ticConfigSchema.d.ts","sourceRoot":"","sources":["../../lib/schema/ticConfigSchema.ts"],"names":[],"mappings":"AAGA;;;;GAIG;AACH,wBAAgB,mBAAmB,IAAI,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAgB7D"}
|