@solid-stack/mason 1.0.12 → 1.0.14
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/dist/bin.cjs +750 -217
- package/dist/bin.cjs.map +1 -1
- package/dist/bin.js +747 -214
- package/dist/bin.js.map +1 -1
- package/dist/cli.d.ts.map +1 -1
- package/dist/commands/create.d.ts.map +1 -1
- package/dist/commands/feature.d.ts.map +1 -1
- package/dist/commands/import.d.ts +23 -0
- package/dist/commands/import.d.ts.map +1 -1
- package/dist/commands/menu.d.ts.map +1 -1
- package/dist/commands/shared.d.ts +2 -0
- package/dist/commands/shared.d.ts.map +1 -0
- package/dist/core/sharedGenerator.d.ts +13 -0
- package/dist/core/sharedGenerator.d.ts.map +1 -0
- package/dist/index.cjs +770 -217
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +4 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +758 -215
- package/dist/index.js.map +1 -1
- package/dist/utils/config.d.ts +35 -0
- package/dist/utils/config.d.ts.map +1 -0
- package/dist/utils/integrity.d.ts +11 -0
- package/dist/utils/integrity.d.ts.map +1 -0
- package/dist/utils/project.d.ts +18 -2
- package/dist/utils/project.d.ts.map +1 -1
- package/dist/utils/registry.d.ts +2 -0
- package/dist/utils/registry.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/cli.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":"AASA,wBAAgB,SAAS,sBAiMxB;AAWD,wBAAsB,MAAM,CAAC,IAAI,GAAE,MAAM,EAAiB,GAAG,OAAO,CAAC,IAAI,CAAC,CAGzE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create.d.ts","sourceRoot":"","sources":["../../src/commands/create.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"create.d.ts","sourceRoot":"","sources":["../../src/commands/create.ts"],"names":[],"mappings":"AAYA,wBAAsB,YAAY,CAChC,IAAI,CAAC,EAAE,MAAM,EACb,IAAI,CAAC,EAAE,MAAM,EACb,KAAK,GAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAM,GAC9B,OAAO,CAAC,IAAI,CAAC,CA0Cf"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"feature.d.ts","sourceRoot":"","sources":["../../src/commands/feature.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"feature.d.ts","sourceRoot":"","sources":["../../src/commands/feature.ts"],"names":[],"mappings":"AAYA,wBAAsB,iBAAiB,CACrC,cAAc,CAAC,EAAE,MAAM,EACvB,KAAK,GAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAM,GAC9B,OAAO,CAAC,IAAI,CAAC,CAqWf"}
|
|
@@ -1,10 +1,33 @@
|
|
|
1
|
+
import * as p from "@clack/prompts";
|
|
1
2
|
export interface ImportFlags {
|
|
2
3
|
overwrite?: boolean;
|
|
3
4
|
dryRun?: boolean;
|
|
4
5
|
yes?: boolean;
|
|
5
6
|
registry?: string;
|
|
6
7
|
skipInstall?: boolean;
|
|
8
|
+
alias?: Record<string, string>;
|
|
7
9
|
[key: string]: any;
|
|
8
10
|
}
|
|
11
|
+
export declare const importPrompts: {
|
|
12
|
+
select: <Value>(opts: p.SelectOptions<Value>) => Promise<Value | typeof p.CANCEL_SYMBOL>;
|
|
13
|
+
text: (opts: p.TextOptions) => Promise<string | typeof p.CANCEL_SYMBOL>;
|
|
14
|
+
};
|
|
15
|
+
/**
|
|
16
|
+
* Rewrite import strings across file content based on an alias mapping.
|
|
17
|
+
* E.g. "@/shared/hasher/" -> "@/shared/auth-hasher/"
|
|
18
|
+
*/
|
|
19
|
+
export declare function rewriteImports(content: string, aliasMap: Map<string, string>): string;
|
|
20
|
+
/**
|
|
21
|
+
* Determine the destination directory for a module type ('src/shared' or 'src/features')
|
|
22
|
+
*/
|
|
23
|
+
export declare function getModuleBaseDir(projectRoot: string, modType: "shared" | "feature"): string;
|
|
24
|
+
/**
|
|
25
|
+
* Resolves the existing directory path for a module in the project, checking both src/<folder>/<name> and <folder>/<name>.
|
|
26
|
+
*/
|
|
27
|
+
export declare function getExistingModuleDir(projectRoot: string, modType: "shared" | "feature", modName: string): string | null;
|
|
28
|
+
/**
|
|
29
|
+
* Check whether a module already exists in the project (checking both src/<folder>/<name> and <folder>/<name>)
|
|
30
|
+
*/
|
|
31
|
+
export declare function checkModuleExists(projectRoot: string, modType: "shared" | "feature", modName: string): boolean;
|
|
9
32
|
export declare function handleImport(typeArg?: string, nameArg?: string, flags?: ImportFlags): Promise<void>;
|
|
10
33
|
//# sourceMappingURL=import.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"import.d.ts","sourceRoot":"","sources":["../../src/commands/import.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"import.d.ts","sourceRoot":"","sources":["../../src/commands/import.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,CAAC,MAAM,gBAAgB,CAAC;AAiBpC,MAAM,WAAW,WAAW;IAC1B,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,GAAG,CAAC,EAAE,OAAO,CAAC;IACd,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAC/B,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;CACpB;AAED,eAAO,MAAM,aAAa;IACxB,MAAM;IACN,IAAI;CACL,CAAC;AAEF;;;GAGG;AACH,wBAAgB,cAAc,CAAC,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,MAAM,CAerF;AAED;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,WAAW,EAAE,MAAM,EAAE,OAAO,EAAE,QAAQ,GAAG,SAAS,GAAG,MAAM,CAG3F;AAED;;GAEG;AACH,wBAAgB,oBAAoB,CAClC,WAAW,EAAE,MAAM,EACnB,OAAO,EAAE,QAAQ,GAAG,SAAS,EAC7B,OAAO,EAAE,MAAM,GACd,MAAM,GAAG,IAAI,CAOf;AAED;;GAEG;AACH,wBAAgB,iBAAiB,CAC/B,WAAW,EAAE,MAAM,EACnB,OAAO,EAAE,QAAQ,GAAG,SAAS,EAC7B,OAAO,EAAE,MAAM,GACd,OAAO,CAET;AAuKD,wBAAsB,YAAY,CAChC,OAAO,CAAC,EAAE,MAAM,EAChB,OAAO,CAAC,EAAE,MAAM,EAChB,KAAK,GAAE,WAAgB,GACtB,OAAO,CAAC,IAAI,CAAC,CAyNf"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"menu.d.ts","sourceRoot":"","sources":["../../src/commands/menu.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"menu.d.ts","sourceRoot":"","sources":["../../src/commands/menu.ts"],"names":[],"mappings":"AAYA,wBAAsB,kBAAkB,CAAC,KAAK,GAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CA6EvF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"shared.d.ts","sourceRoot":"","sources":["../../src/commands/shared.ts"],"names":[],"mappings":"AAUA,wBAAsB,gBAAgB,CACpC,aAAa,CAAC,EAAE,MAAM,EACtB,KAAK,GAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAM,GAC9B,OAAO,CAAC,IAAI,CAAC,CAqFf"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { GeneratedFile } from "../types/index.js";
|
|
2
|
+
export interface SharedOptions {
|
|
3
|
+
name: string;
|
|
4
|
+
description?: string;
|
|
5
|
+
projectRoot?: string;
|
|
6
|
+
targetDir?: string;
|
|
7
|
+
dryRun?: boolean;
|
|
8
|
+
overwrite?: boolean;
|
|
9
|
+
includeStub?: boolean;
|
|
10
|
+
isRegistry?: boolean;
|
|
11
|
+
}
|
|
12
|
+
export declare function generateShared(options: SharedOptions): GeneratedFile[];
|
|
13
|
+
//# sourceMappingURL=sharedGenerator.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sharedGenerator.d.ts","sourceRoot":"","sources":["../../src/core/sharedGenerator.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAKvD,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAED,wBAAgB,cAAc,CAAC,OAAO,EAAE,aAAa,GAAG,aAAa,EAAE,CAiHtE"}
|