depflow 3.0.0-dev.1 → 3.0.0-dev.10

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.
Files changed (76) hide show
  1. package/build/cli/DepFLowCLI.d.ts +1 -0
  2. package/build/cli/DepFLowCLI.js +36 -5
  3. package/build/cli/DepFLowCLI.js.map +1 -1
  4. package/build/cli/bin.js +2 -5
  5. package/build/cli/bin.js.map +1 -1
  6. package/build/config/Config.d.ts +3 -3
  7. package/build/config/Config.js +3 -3
  8. package/build/config/Config.js.map +1 -1
  9. package/build/config/ImportMap.d.ts +24 -10
  10. package/build/config/ImportMap.js +39 -24
  11. package/build/config/ImportMap.js.map +1 -1
  12. package/build/config/{Tsconfig.d.ts → TSConfig.d.ts} +14 -17
  13. package/build/config/{Tsconfig.js → TSConfig.js} +39 -35
  14. package/build/config/TSConfig.js.map +1 -0
  15. package/build/schema/Config/Builder.d.ts +431 -0
  16. package/build/schema/Config/Builder.js +48 -0
  17. package/build/schema/Config/Builder.js.map +1 -0
  18. package/build/schema/Config/Config.d.ts +582 -0
  19. package/build/schema/Config/Config.js +20 -0
  20. package/build/schema/Config/Config.js.map +1 -0
  21. package/build/schema/Config/Dependency.d.ts +748 -0
  22. package/build/schema/Config/Dependency.js +25 -0
  23. package/build/schema/Config/Dependency.js.map +1 -0
  24. package/build/schema/Config/Extractor.d.ts +133 -0
  25. package/build/schema/Config/Extractor.js +25 -0
  26. package/build/schema/Config/Extractor.js.map +1 -0
  27. package/build/schema/Config/Resolver.d.ts +70 -0
  28. package/build/schema/Config/Resolver.js +25 -0
  29. package/build/schema/Config/Resolver.js.map +1 -0
  30. package/build/schema/Config/Transform.d.ts +73 -0
  31. package/build/schema/Config/Transform.js +27 -0
  32. package/build/schema/Config/Transform.js.map +1 -0
  33. package/build/schema/ImportMap.d.ts +22 -0
  34. package/build/schema/ImportMap.js +12 -0
  35. package/build/schema/ImportMap.js.map +1 -0
  36. package/build/schema/TSConfig.d.ts +56 -0
  37. package/build/schema/TSConfig.js +19 -0
  38. package/build/schema/TSConfig.js.map +1 -0
  39. package/build/schema/schema.d.ts +29 -0
  40. package/build/schema/schema.js +31 -0
  41. package/build/schema/schema.js.map +1 -0
  42. package/build/support/Builder/Builder.d.ts +16 -6
  43. package/build/support/Builder/Builder.js +57 -30
  44. package/build/support/Builder/Builder.js.map +1 -1
  45. package/build/support/Dependency/Dependency.d.ts +5 -5
  46. package/build/support/Dependency/Dependency.js +1 -1
  47. package/build/support/Dependency/Dependency.js.map +1 -1
  48. package/build/support/Dependency/GitDependency.d.ts +2 -2
  49. package/build/support/Dependency/GitDependency.js +1 -1
  50. package/build/support/Dependency/GitDependency.js.map +1 -1
  51. package/build/support/Dependency/NpmDependency.d.ts +3 -3
  52. package/build/support/Dependency/NpmDependency.js +1 -1
  53. package/build/support/Dependency/NpmDependency.js.map +1 -1
  54. package/build/support/Git.js +1 -1
  55. package/build/support/Git.js.map +1 -1
  56. package/build/support/PathResolver/AliasCompiler.d.ts +13 -6
  57. package/build/support/PathResolver/AliasCompiler.js +35 -12
  58. package/build/support/PathResolver/AliasCompiler.js.map +1 -1
  59. package/build/support/PathResolver/PathResolver.d.ts +4 -4
  60. package/build/support/PathResolver/PathResolver.js +23 -22
  61. package/build/support/PathResolver/PathResolver.js.map +1 -1
  62. package/build/support/Task/Task.js +1 -1
  63. package/build/support/Task/Task.js.map +1 -1
  64. package/build/support/Utils.d.ts +1 -1
  65. package/build/support/Utils.js.map +1 -1
  66. package/package.json +6 -7
  67. package/build/config/Tsconfig.js.map +0 -1
  68. package/build/config/schemas.d.ts +0 -1194
  69. package/build/config/schemas.js +0 -66
  70. package/build/config/schemas.js.map +0 -1
  71. package/build/support/Async.d.ts +0 -22
  72. package/build/support/Async.js +0 -62
  73. package/build/support/Async.js.map +0 -1
  74. package/build/support/Dependency/Resolver.d.ts +0 -7
  75. package/build/support/Dependency/Resolver.js +0 -4
  76. package/build/support/Dependency/Resolver.js.map +0 -1
@@ -7,6 +7,7 @@ export declare class DepFlowCLI extends DebugUI {
7
7
  commandRemove(command: string, args: string[]): Promise<void>;
8
8
  commandInstall(command: string, args: string[]): Promise<void>;
9
9
  uninstall(command: string, args: string[]): Promise<void>;
10
+ commandRun(command: string, args: string[]): Promise<void>;
10
11
  list(command: string, args: string[]): Promise<void>;
11
12
  rewritePaths(command: string, args: string[]): Promise<void>;
12
13
  commandSync(command: string, args: string[]): Promise<void>;
@@ -5,10 +5,11 @@ import Validator from "../support/Validator.js";
5
5
  import GitDependency from "../support/Dependency/GitDependency.js";
6
6
  import PathResolver from "../support/PathResolver/PathResolver.js";
7
7
  import Config from "../config/Config.js";
8
- import Schemas from "../config/schemas.js";
9
- import Tsconfig from "../config/Tsconfig.js";
8
+ import schema from "../schema/schema.js";
9
+ import TSConfig from "../config/TSConfig.js";
10
10
  import ImportMap from "../config/ImportMap.js";
11
11
  import NpmDependency from "../support/Dependency/NpmDependency.js";
12
+ import Builder from "../support/Builder/Builder.js";
12
13
  export class DepFlowCLI extends DebugUI {
13
14
  configPath;
14
15
  projectRoot;
@@ -25,6 +26,7 @@ export class DepFlowCLI extends DebugUI {
25
26
  this.addCommand('remove', this.commandRemove, { usage: 'dep remove <name> | <repo_url>', description: 'Remove a dependency from the configuration file by name or repo URL.' });
26
27
  this.addCommand('install', this.commandInstall, { usage: 'dep install [name1 name2 ...]', description: 'Install dependencies. If names are provided, only those dependencies will be installed.' });
27
28
  this.addCommand('uninstall', this.uninstall, { usage: 'dep uninstall [name1 name2 ...]', description: 'Uninstall dependencies. If names are provided, only those dependencies will be uninstalled.' });
29
+ this.addCommand('run', this.commandRun, { usage: 'dep run <script>', description: 'Run a custom action defined in the configuration file.' });
28
30
  this.addCommand('list', this.list, { usage: 'dep list', description: 'List all dependencies in the configuration file.' });
29
31
  this.addCommand('rewrite-paths', this.rewritePaths, { usage: 'dep rewrite-paths [--watch] [--cdn]', description: 'Resolve and rewrite paths in built files based on depFlow configuration.' });
30
32
  this.addCommand('sync', this.commandSync, { usage: 'dep sync', description: 'Syncs depFlow.json with tsconfig.json and generates the importmap.' });
@@ -37,7 +39,7 @@ export class DepFlowCLI extends DebugUI {
37
39
  Validator.validateRepo(repo);
38
40
  if (!name)
39
41
  name = Utils.getRepoName(repo);
40
- const dep = Schemas.GitDependency.processData({ name, repo });
42
+ const dep = schema.Dependency.GitDependency.processData({ name, repo });
41
43
  const config = await Config.load(this.configPath);
42
44
  config.dependencies.push(dep);
43
45
  await Config.save(this.configPath, config);
@@ -144,6 +146,32 @@ export class DepFlowCLI extends DebugUI {
144
146
  this.out.groupEnd();
145
147
  }
146
148
  }
149
+ async commandRun(command, args) {
150
+ try {
151
+ const [actionName] = args;
152
+ if (!actionName)
153
+ throw new Error('Usage: dep run <action>');
154
+ this.out.group(Utils.newGroup('#FFB4DC'));
155
+ this.out.info(`&C5Running action &C6${actionName}&C5...`);
156
+ const config = await Config.load(this.configPath);
157
+ const action = config.actions[actionName];
158
+ if (!action)
159
+ throw new Error(`action "${actionName}" not found in configuration.`);
160
+ const pipeline = Array.isArray(action) ? action : [action];
161
+ const builder = new Builder({
162
+ cwd: this.projectRoot,
163
+ pipeline,
164
+ logger: this.out
165
+ });
166
+ await builder.run();
167
+ }
168
+ catch (error) {
169
+ this.out.error(`&C1${error}`);
170
+ }
171
+ finally {
172
+ this.out.groupEnd();
173
+ }
174
+ }
147
175
  async list(command, args) {
148
176
  this.out.group(Utils.newGroup('#FFB4DC'));
149
177
  try {
@@ -169,6 +197,7 @@ export class DepFlowCLI extends DebugUI {
169
197
  const watch = args.includes('--watch') || args.includes('-w');
170
198
  const useCDN = args.includes('--cdn');
171
199
  const mode = useCDN ? 'cdn' : 'local';
200
+ const dir = config.outDir;
172
201
  this.out.info(`Mode: &C3${useCDN ? 'CDN' : 'Local'}`);
173
202
  if (watch)
174
203
  this.out.info(`Watcher: &C2Enabled`);
@@ -195,15 +224,17 @@ export class DepFlowCLI extends DebugUI {
195
224
  const resolver = new PathResolver(config, { logger: this.out });
196
225
  const tsconfigFile = config.tsconfig;
197
226
  const importMapFile = config.importmap;
227
+ const tsconfigPath = path.join(this.projectRoot, tsconfigFile || 'tsconfig.json');
228
+ const importMapPath = path.join(this.projectRoot, importMapFile || 'importmap.json');
198
229
  if (tsconfigFile) {
199
- const tsconfig = await Tsconfig.load(this.projectRoot, tsconfigFile, { logger: this.out });
230
+ const tsconfig = await TSConfig.load(tsconfigPath, { logger: this.out });
200
231
  tsconfig.updatePaths(resolver.aliases);
201
232
  await tsconfig.save();
202
233
  }
203
234
  else
204
235
  this.out.warn(`No tsconfig file specified in configuration. Skipping tsconfig synchronization.`);
205
236
  if (importMapFile) {
206
- const importmap = await ImportMap.load(this.projectRoot, importMapFile, { logger: this.out });
237
+ const importmap = await ImportMap.load(importMapPath, { logger: this.out });
207
238
  importmap.updateImports(resolver.aliases, mode);
208
239
  await importmap.save();
209
240
  }
@@ -1 +1 @@
1
- {"version":3,"file":"DepFLowCLI.js","sourceRoot":"","sources":["../../src/cli/DepFLowCLI.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,OAAO,MAAM,EAAE,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAEjD,OAAO,KAAK,MAAM,qBAAqB,CAAC;AACxC,OAAO,SAAS,MAAM,yBAAyB,CAAC;AAChD,OAAO,aAAa,MAAM,wCAAwC,CAAC;AACnE,OAAO,YAAY,MAAM,yCAAyC,CAAC;AACnE,OAAO,MAAM,MAAM,qBAAqB,CAAC;AACzC,OAAO,OAAO,MAAM,sBAAsB,CAAC;AAC3C,OAAO,QAAQ,MAAM,uBAAuB,CAAC;AAC7C,OAAO,SAAS,MAAM,wBAAwB,CAAC;AAC/C,OAAO,aAAa,MAAM,wCAAwC,CAAC;AAEnE,MAAM,OAAO,UAAW,SAAQ,OAAO;IAGf;IAFD,WAAW,CAAS;IACvC,YACoB,aAAqB,cAAc;QACnD,KAAK,EAAE,CAAC;QADQ,eAAU,GAAV,UAA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C,yBAAyB,KAAK,EAAE,CAAC,CAAC;QAAC,CAAC;gBAC7D,CAAC;YAAC,IAAI,CAAC,GAAG,CAAC,QAAQ,EAAE,CAAC;QAAC,CAAC;IACpC,CAAC;CACJ;AAED,eAAe,UAAU,CAAC"}
package/build/cli/bin.js CHANGED
@@ -2,13 +2,10 @@
2
2
  import { File } from "@netfeez/common-node";
3
3
  import DepFlowCLI from "./DepFLowCLI.js";
4
4
  import { Utils } from "../support/Utils.js";
5
- import Schemas from "../config/schemas.js";
5
+ import schema from "../schema/schema.js";
6
6
  async function startupSchemaValidation(flowPath) {
7
- const jsonSchema = Schemas.Config.jsonSchema;
8
- // Temporarily write the schema to the .depflow directory for validation purposes
9
- // The vscode configuration was out for now, while ill enhance it we will use the $schema property in the depflow.json file to point to this schema
7
+ const jsonSchema = schema.Config.jsonSchema;
10
8
  File.write(`.depflow/schema.json`, JSON.stringify(jsonSchema));
11
- // Utils.addVscodeValidation(flowPath, jsonSchema);
12
9
  }
13
10
  const skip = 2;
14
11
  const [commandName, ...argsList] = process.argv.slice(skip);
@@ -1 +1 @@
1
- {"version":3,"file":"bin.js","sourceRoot":"","sources":["../../src/cli/bin.ts"],"names":[],"mappings":";AACA,OAAO,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AAE5C,OAAO,UAAU,MAAM,iBAAiB,CAAC;AACzC,OAAO,EAAE,KAAK,EAAE,MAAM,qBAAqB,CAAC;AAC5C,OAAO,OAAO,MAAM,sBAAsB,CAAC;AAE3C,KAAK,UAAU,uBAAuB,CAAC,QAAgB;IACnD,MAAM,UAAU,GAAG,OAAO,CAAC,MAAM,CAAC,UAAU,CAAC;IAC7C,iFAAiF;IACjF,mJAAmJ;IACnJ,IAAI,CAAC,KAAK,CAAC,sBAAsB,EAAE,IAAI,CAAC,SAAS,CAAC,UAAU,CAAC,CAAC,CAAC;IAC/D,mDAAmD;AACvD,CAAC;AAED,MAAM,IAAI,GAAG,CAAC,CAAC;AACf,MAAM,CAAC,W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AE,CAAC;QACvB,MAAM,OAAO,GAAG,GAAG,CAAC,UAAU,CAAC,WAAW,CAAC,CAAC;QAC5C,IAAI,OAAO,EAAE,CAAC;YACV,MAAM,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,GAAG,EAAE,WAAW,EAAE,IAAI,CAAC,CAAC;QACpD,CAAC;aAAM,CAAC;YACJ,GAAG,CAAC,GAAG,CAAC,KAAK,CAAC,oBAAoB,WAAW,EAAE,CAAC,CAAC;YACjD,GAAG,CAAC,UAAU,CAAC,MAAM,CAAC,EAAE,IAAI,CAAC,IAAI,CAAC,GAAG,EAAE,MAAM,EAAE,EAAE,CAAC,CAAC;QACvD,CAAC;IACL,CAAC;;QAAM,GAAG,CAAC,KAAK,EAAE,CAAC;AACvB,CAAC;AAAC,OAAO,KAAU,EAAE,CAAC;IAClB,GAAG,CAAC,GAAG,CAAC,KAAK,CAAC,2DAA2D,CAAC,CAAC;IAC3E,GAAG,CAAC,GAAG,CAAC,KAAK,CAAC,mBAAmB,KAAK,EAAE,KAAK,IAAI,KAAK,EAAE,CAAC,CAAC;IAC1D,GAAG,CAAC,GAAG,CAAC,KAAK,CAAC,2DAA2D,CAAC,CAAC;IAC3E,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAA;AACnB,CAAC"}
@@ -1,4 +1,4 @@
1
- import Schemas from './schemas.js';
1
+ import schema from '../schema/schema.js';
2
2
  export declare class Config {
3
3
  /**
4
4
  * Loads the configuration from a file at the specified path.
@@ -22,7 +22,7 @@ export declare class Config {
22
22
  static save(path: string, config: Config.ConfigToProcess): Promise<void>;
23
23
  }
24
24
  export declare namespace Config {
25
- type Config = typeof Schemas.Config.infer;
26
- type ConfigToProcess = typeof Schemas.Config.inferToProcess;
25
+ type Config = schema.Config;
26
+ type ConfigToProcess = schema.Config.toProcess;
27
27
  }
28
28
  export default Config;
@@ -4,7 +4,7 @@
4
4
  * @license Apache-2.0
5
5
  */
6
6
  import { File } from '@netfeez/common-node';
7
- import Schemas from './schemas.js';
7
+ import schema from '../schema/schema.js';
8
8
  export class Config {
9
9
  /**
10
10
  * Loads the configuration from a file at the specified path.
@@ -17,14 +17,14 @@ export class Config {
17
17
  */
18
18
  static async load(path) {
19
19
  if (!await File.exists(path)) {
20
- const defaults = Schemas.Config.processData({});
20
+ const defaults = schema.Config.processData({});
21
21
  await Config.save(path, defaults);
22
22
  return defaults;
23
23
  }
24
24
  else {
25
25
  const content = await File.read(path, 'utf-8');
26
26
  const json = JSON.parse(content);
27
- const config = Schemas.Config.processData(json);
27
+ const config = schema.Config.processData(json);
28
28
  return config;
29
29
  }
30
30
  }
@@ -1 +1 @@
1
- {"version":3,"file":"Config.js","sourceRoot":"","sources":["../../src/config/Config.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AAE5C,OAAO,OAAO,MAAM,cAAc,CAAC;AAEnC,MAAM,OAAO,MAAM;IACf;;;;;;;;OAQG;IACH,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,IAAY;QAC1B,IAAI,CAAC,MAAM,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,EAAE,CAAC;YAC3B,MAAM,QAAQ,GAAG,OAAO,CAAC,MAAM,CAAC,WAAW,CAAC,EAAE,CAAC,CAAC;YAChD,MAAM,MAAM,CAAC,IAAI,CAAC,IAAI,EAAE,QAAQ,CAAC,CAAC;YAClC,OAAO,QAAQ,CAAC;QACpB,CAAC;aAAM,CAAC;YACJ,MAAM,OAAO,GAAG,MAAM,IAAI,CAAC,IAAI,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;YAC/C,MAAM,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;YACjC,MAAM,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;YAChD,OAAO,MAAM,CAAC;QAClB,CAAC;IACL,CAAC;IACD;;;;;;;;OAQG;IACH,MA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E,CAAC,CAAC,CAAC;QAChD,MAAM,IAAI,CAAC,KAAK,CAAC,IAAI,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;IAC7C,CAAC;CACJ;AAMD,eAAe,MAAM,CAAC"}
@@ -1,12 +1,11 @@
1
1
  import { Logger } from '@netfeez/vterm';
2
2
  import AliasCompiler from '../support/PathResolver/AliasCompiler.js';
3
- import Schemas from './schemas.js';
3
+ import schema from '../schema/schema.js';
4
4
  export declare class ImportMap {
5
5
  protected data: ImportMap.Data;
6
- protected projectRoot: string;
7
- protected filename: string;
6
+ protected path: string;
8
7
  protected logger: Logger;
9
- constructor(data: ImportMap.Data, projectRoot: string, filename: string, options?: ImportMap.Options);
8
+ constructor(data: ImportMap.Data, path: string, options?: ImportMap.Options);
10
9
  /**
11
10
  * Updates the import map data based on the provided compiled aliases.
12
11
  * It constructs an "imports" section where each alias is mapped to its target path.
@@ -14,22 +13,37 @@ export declare class ImportMap {
14
13
  * @param mode The resolution mode ('local' or 'cdn').
15
14
  */
16
15
  updateImports(aliases: AliasCompiler.CompiledAlias[], mode: 'local' | 'cdn'): void;
17
- save(filename?: string): Promise<void>;
18
- static save(projectRoot: string, filename: string, data: ImportMap.Data, options?: ImportMap.Options): Promise<void>;
16
+ /**
17
+ * Saves the provided import map data to a specified file path.
18
+ * It ensures that the directory for the file exists, converts the data to a JSON string with proper formatting, and writes it to the file system.
19
+ * The method also includes logging to inform users when the save operation is successful.
20
+ * @param path The path to the import map file to save.
21
+ * @returns A promise that resolves when the save operation is complete, or rejects if an error occurs during the process.
22
+ */
23
+ save(path?: string): Promise<void>;
24
+ /**
25
+ * Saves the provided import map data to a specified file path.
26
+ * It ensures that the directory for the file exists, converts the data to a JSON string with proper formatting, and writes it to the file system.
27
+ * The method also includes logging to inform users when the save operation is successful.
28
+ * @param path The path to the import map file to save.
29
+ * @param data The import map data to be saved.
30
+ * @param options Additional options for saving, such as a logger for logging messages during the save process.
31
+ * @returns A promise that resolves when the save operation is complete, or rejects if an error occurs during the process.
32
+ */
33
+ static save(path: string, data: ImportMap.Data, options?: ImportMap.Options): Promise<void>;
19
34
  /**
20
35
  * Factory method: Loads, validates (or creates default), and returns an instance of the ImportMap class.
21
36
  * It checks if the specified import map file exists, and if it does, it attempts to read and parse its content as JSON.
22
37
  * If the file does not exist or contains invalid JSON, it initializes the data with a default structure containing an empty "imports" object.
23
38
  * Finally, it returns a new instance of ImportMap with the loaded or default data, allowing for further manipulation and saving of the import map configuration.
24
- * @param projectRoot The root directory of the project where the import map file is located.
25
- * @param filename The name of the import map file to load (e.g., 'import-map.json').
39
+ * @param path The path to the import map file to load.
26
40
  * @param options Additional options for loading, such as a logger for logging messages during the load process.
27
41
  * @returns A promise that resolves to an instance of ImportMap initialized with the loaded or default data.
28
42
  */
29
- static load(projectRoot: string, filename: string, options?: ImportMap.Options): Promise<ImportMap>;
43
+ static load(path: string, options?: ImportMap.Options): Promise<ImportMap>;
30
44
  }
31
45
  export declare namespace ImportMap {
32
- type Data = Schemas.ImportMap['infer'];
46
+ type Data = schema.ImportMap.Root;
33
47
  interface Options {
34
48
  logger?: Logger;
35
49
  }
@@ -1,16 +1,13 @@
1
- import PATH from 'node:path';
2
1
  import { Logger } from '@netfeez/vterm';
3
2
  import { File, Path } from '@netfeez/common-node';
4
- import Schemas from './schemas.js';
3
+ import schema from '../schema/schema.js';
5
4
  export class ImportMap {
6
5
  data;
7
- projectRoot;
8
- filename;
6
+ path;
9
7
  logger;
10
- constructor(data, projectRoot, filename, options = {}) {
8
+ constructor(data, path, options = {}) {
11
9
  this.data = data;
12
- this.projectRoot = projectRoot;
13
- this.filename = filename;
10
+ this.path = path;
14
11
  this.logger = options.logger || new Logger({ name: 'IMP-MAP' });
15
12
  }
16
13
  /**
@@ -22,14 +19,15 @@ export class ImportMap {
22
19
  updateImports(aliases, mode) {
23
20
  if (!this.data.imports)
24
21
  this.data.imports = {};
22
+ const projectRoot = Path.dirname(this.path);
25
23
  for (const aliasObj of aliases) {
26
24
  const key = aliasObj.isWildcard ? `${aliasObj.alias}/` : aliasObj.alias;
27
25
  let target = mode === 'cdn' && aliasObj.targets.cdn
28
26
  ? aliasObj.targets.cdn
29
27
  : aliasObj.targets.local;
30
28
  if (target === aliasObj.targets.local) {
31
- target = Path.diff(this.projectRoot, target);
32
- target = target.startsWith('/') ? target : `/${target}`;
29
+ target = Path.diff(projectRoot, target);
30
+ target = target.startsWith('.') ? target : `./${target}`;
33
31
  target = Path.normalize(target);
34
32
  }
35
33
  if (aliasObj.isWildcard) {
@@ -39,16 +37,34 @@ export class ImportMap {
39
37
  this.data.imports[key] = target;
40
38
  }
41
39
  }
42
- async save(filename = this.filename) {
43
- await ImportMap.save(this.projectRoot, filename, this.data, { logger: this.logger });
40
+ /**
41
+ * Saves the provided import map data to a specified file path.
42
+ * It ensures that the directory for the file exists, converts the data to a JSON string with proper formatting, and writes it to the file system.
43
+ * The method also includes logging to inform users when the save operation is successful.
44
+ * @param path The path to the import map file to save.
45
+ * @returns A promise that resolves when the save operation is complete, or rejects if an error occurs during the process.
46
+ */
47
+ async save(path = this.path) {
48
+ await ImportMap.save(path, this.data, { logger: this.logger });
49
+ if (path !== this.path)
50
+ this.path = path;
44
51
  }
45
- static async save(projectRoot, filename, data, options = {}) {
52
+ /**
53
+ * Saves the provided import map data to a specified file path.
54
+ * It ensures that the directory for the file exists, converts the data to a JSON string with proper formatting, and writes it to the file system.
55
+ * The method also includes logging to inform users when the save operation is successful.
56
+ * @param path The path to the import map file to save.
57
+ * @param data The import map data to be saved.
58
+ * @param options Additional options for saving, such as a logger for logging messages during the save process.
59
+ * @returns A promise that resolves when the save operation is complete, or rejects if an error occurs during the process.
60
+ */
61
+ static async save(path, data, options = {}) {
46
62
  const logger = options.logger || new Logger({ name: 'IMP-MAP' });
47
- const importMapPath = PATH.resolve(projectRoot, filename);
48
- const folder = PATH.dirname(importMapPath);
63
+ const folder = Path.dirname(path);
49
64
  await File.ensureDir(folder);
50
65
  const json = JSON.stringify(data, null, 4);
51
- await File.write(importMapPath, json);
66
+ await File.write(path, json);
67
+ const filename = Path.fileName(path);
52
68
  logger.log(`&C2Saved file &C4${filename}`);
53
69
  }
54
70
  /**
@@ -56,26 +72,25 @@ export class ImportMap {
56
72
  * It checks if the specified import map file exists, and if it does, it attempts to read and parse its content as JSON.
57
73
  * If the file does not exist or contains invalid JSON, it initializes the data with a default structure containing an empty "imports" object.
58
74
  * Finally, it returns a new instance of ImportMap with the loaded or default data, allowing for further manipulation and saving of the import map configuration.
59
- * @param projectRoot The root directory of the project where the import map file is located.
60
- * @param filename The name of the import map file to load (e.g., 'import-map.json').
75
+ * @param path The path to the import map file to load.
61
76
  * @param options Additional options for loading, such as a logger for logging messages during the load process.
62
77
  * @returns A promise that resolves to an instance of ImportMap initialized with the loaded or default data.
63
78
  */
64
- static async load(projectRoot, filename, options = {}) {
79
+ static async load(path, options = {}) {
65
80
  const logger = options.logger || new Logger({ name: 'IMP-MAP' });
66
- const importMapPath = PATH.resolve(projectRoot, filename);
67
81
  let data;
68
- if (!await File.exists(importMapPath)) {
82
+ if (!await File.exists(path)) {
83
+ const filename = Path.fileName(path);
69
84
  logger.warn(`&C3${filename} not found. Creating defaults...`);
70
- data = Schemas.ImportMap.processData({});
85
+ data = schema.ImportMap.processData({});
71
86
  // await ImportMap.save(projectRoot, filename, data, { logger });
72
87
  }
73
88
  else {
74
- const content = await File.read(importMapPath, 'utf-8');
89
+ const content = await File.read(path, 'utf-8');
75
90
  const json = JSON.parse(content);
76
- data = Schemas.ImportMap.processData(json);
91
+ data = schema.ImportMap.processData(json);
77
92
  }
78
- return new ImportMap(data, projectRoot, filename, { logger });
93
+ return new ImportMap(data, path, { logger });
79
94
  }
80
95
  }
81
96
  export default ImportMap;
@@ -1 +1 @@
1
- {"version":3,"file":"ImportMap.js","sourceRoot":"","sources":["../../src/config/ImportMap.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,OAAO,EAAE,MAAM,EAAE,MAAM,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I,IAAI,MAAM,CAAC,EAAE,IAAI,EAAE,SAAS,EAAE,CAAC,CAAC;QACjE,IAAI,IAAoB,CAAC;QACzB,IAAI,CAAC,MAAM,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,EAAE,CAAC;YAC3B,MAAM,QAAQ,GAAG,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;YACrC,MAAM,CAAC,IAAI,CAAC,MAAM,QAAQ,kCAAkC,CAAC,CAAC;YAC9D,IAAI,GAAG,MAAM,CAAC,SAAS,CAAC,WAAW,CAAC,EAAE,CAAC,CAAC;YACxC,iEAAiE;QACrE,CAAC;aAAM,CAAC;YACJ,MAAM,OAAO,GAAG,MAAM,IAAI,CAAC,IAAI,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;YAC/C,MAAM,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;YACjC,IAAI,GAAG,MAAM,CAAC,SAAS,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;QAC9C,CAAC;QAAC,OAAO,IAAI,SAAS,CAAC,IAAI,EAAE,IAAI,EAAE,EAAE,MAAM,EAAE,CAAC,CAAC;IACnD,CAAC;CACJ;AAOD,eAAe,SAAS,CAAC"}
@@ -1,12 +1,11 @@
1
1
  import { Logger } from '@netfeez/vterm';
2
- import Schemas from "./schemas.js";
3
2
  import AliasCompiler from '../support/PathResolver/AliasCompiler.js';
4
- export declare class Tsconfig {
5
- protected data: Tsconfig.Data;
6
- protected projectRoot: string;
7
- protected filename: string;
3
+ import schema from '../schema/schema.js';
4
+ export declare class TSConfig {
5
+ protected data: TSConfig.Data;
6
+ protected path: string;
8
7
  protected logger: Logger;
9
- constructor(data: Tsconfig.Data, projectRoot: string, filename: string, options?: Tsconfig.Options);
8
+ constructor(data: TSConfig.Data, path: string, options?: TSConfig.Options);
10
9
  /**
11
10
  * Updates the paths in the tsconfig data based on the provided compiled aliases.
12
11
  * It ensures that the compilerOptions and paths properties exist in the tsconfig data, and then iterates through the compiled aliases to construct the appropriate path mappings.
@@ -19,39 +18,37 @@ export declare class Tsconfig {
19
18
  * Saves the current tsconfig data to a file.
20
19
  * It constructs the path to the tsconfig file using the project root and filename, converts the data to a JSON string with proper formatting, and writes it to the file system using the File.write method.
21
20
  * The method also includes error handling to log any issues that occur during the save process, ensuring that users are informed of any problems when attempting to save the tsconfig configuration.
22
- * @param filename The name of the tsconfig file to save (default is the instance's filename property).
21
+ * @param path The path to the tsconfig file where the data should be saved.
23
22
  * @returns A promise that resolves when the save operation is complete, or rejects if an error occurs during the process.
24
23
  */
25
- save(filename?: string): Promise<void>;
24
+ save(path?: string): Promise<void>;
26
25
  /**
27
26
  * Static method to save tsconfig data to a specified file. It takes the project root, filename, tsconfig data, and options (including a logger) as parameters.
28
27
  * The method constructs the full path to the tsconfig file, converts the data to a formatted JSON string, and writes it to the file system.
29
28
  * It also includes error handling to log any issues that arise during the save process, providing feedback on whether the operation was successful or if it encountered problems.
30
- * @param projectRoot The root directory of the project where the tsconfig file should be saved.
31
- * @param filename The name of the tsconfig file (default is 'tsconfig.json').
29
+ * @param path The path to the tsconfig file where the data should be saved.
32
30
  * @param data The tsconfig data to be saved, structured according to the defined schema.
33
31
  * @param options Additional options for saving, such as a logger for logging messages during the save process.
34
32
  * @returns A promise that resolves when the save operation is complete, or rejects if an error occurs during the process.
35
33
  * @throws Will throw an error if there is an issue during the save process, which can be caught by the caller to handle it appropriately.
36
34
  */
37
- static save(projectRoot: string, filename: string | undefined, data: Tsconfig.Data, options?: Tsconfig.Options): Promise<void>;
35
+ static save(path: string, data: TSConfig.Data, options?: TSConfig.Options): Promise<void>;
38
36
  /**
39
37
  * Static method to load tsconfig data from a specified file.
40
38
  * It takes the project root, filename, and options (including a logger) as parameters.
41
39
  * The method checks if the tsconfig file exists, and if it does, it reads the content, parses it as JSON, and processes it using the defined schema to ensure it conforms to the expected structure.
42
40
  * If the file does not exist, it creates a default tsconfig data object using the schema. Finally, it returns an instance of the Tsconfig class initialized with the loaded or default data.
43
- * @param projectRoot The root directory of the project where the tsconfig file is located.
44
- * @param filename The name of the tsconfig file to load (default is 'tsconfig.json').
41
+ * @param path The path to the tsconfig file to load.
45
42
  * @param options Additional options for loading, such as a logger for logging messages during the load process.
46
43
  * @returns A promise that resolves to an instance of the Tsconfig class containing the loaded data, or rejects if there is an error during the load process.
47
44
  * @throws Will throw an error if there is an issue during the load process, which
48
45
  */
49
- static load(projectRoot: string, filename: string, options: Tsconfig.Options): Promise<Tsconfig>;
46
+ static load(path: string, options: TSConfig.Options): Promise<TSConfig>;
50
47
  }
51
- export declare namespace Tsconfig {
52
- type Data = Schemas.TsConfig['infer'];
48
+ export declare namespace TSConfig {
49
+ type Data = schema.TSConfig.Root;
53
50
  interface Options {
54
51
  logger?: Logger;
55
52
  }
56
53
  }
57
- export default Tsconfig;
54
+ export default TSConfig;