@domain-first/project-structure 6.0.0 → 7.0.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/README.md +16 -19
- package/dist/201.js +46 -35
- package/dist/287.js +1685 -1612
- package/dist/config-file.d.ts +2 -2
- package/dist/dependency-rules.d.ts +1 -1
- package/dist/file-system.d.ts +5 -0
- package/dist/in-memory-db.d.ts +5 -0
- package/dist/index.cjs +100 -916
- package/dist/index.js +6 -46
- package/dist/init.cjs +868 -0
- package/dist/init.d.ts +2 -0
- package/dist/init.js +36 -0
- package/dist/integration.cjs +412 -33
- package/dist/integration.js +4 -4
- package/dist/integrations/in-memory-db.d.ts +6 -0
- package/dist/integrations/index.d.ts +2 -0
- package/dist/integrations/missing-domain-first-packages.d.ts +8 -0
- package/dist/integrations/rest-endpoint-generator.d.ts +18 -0
- package/dist/integrations/rest-endpoint-generator.spec.d.ts +1 -0
- package/dist/lint.cjs +8 -8
- package/dist/lint.js +7 -7
- package/dist/print-next-steps.d.ts +2 -2
- package/dist/react.cjs +915 -0
- package/dist/react.d.ts +2 -0
- package/dist/react.js +73 -0
- package/dist/use-cases/rest-endpoint-generator.d.ts +1 -1
- package/package.json +3 -1
- package/skills/df-ps-implement/SKILL.md +10 -55
- package/skills/df-ps-plan-feature/SKILL.md +6 -6
- package/skills/df-ps-project-scripts/SKILL.md +1 -1
- package/skills/df-ps-react/SKILL.md +82 -0
- package/skills/df-ps-react/references/generators.md +80 -0
- package/skills/df-ps-scaffold/SKILL.md +38 -20
- package/skills/df-ps-scaffold/references/choosing-components.md +7 -28
- package/skills/df-ps-scaffold/references/generators.md +6 -179
- package/skills/df-ps-scaffold/references/units/aggregate.md +47 -0
- package/skills/df-ps-scaffold/references/units/bounded-context.md +13 -0
- package/skills/df-ps-scaffold/references/units/command-query.md +32 -0
- package/skills/df-ps-scaffold/references/units/endpoint.md +28 -0
- package/skills/df-ps-scaffold/references/units/entity-value-object.md +27 -0
- package/skills/df-ps-scaffold/references/units/errors.md +26 -0
- package/skills/df-ps-scaffold/references/units/port.md +23 -0
- package/skills/df-ps-scaffold/references/units/services.md +28 -0
- package/skills/df-ps-scaffold/references/units/use-case.md +25 -0
- package/skills/df-ps-scaffold/references/units/wire-dependency.md +15 -0
- package/skills/df-ps-scaffold/scripts/drive.mjs +12 -4
package/dist/config-file.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import z from 'zod';
|
|
|
2
2
|
/**
|
|
3
3
|
* `df-lint` checks that `rules.lint` can turn off.
|
|
4
4
|
*/
|
|
5
|
-
export declare const lintChecks: readonly ["context-isolation", "shared-
|
|
5
|
+
export declare const lintChecks: readonly ["context-isolation", "shared-kernel", "layers", "dependencies", "react", "clock"];
|
|
6
6
|
export type LintCheck = (typeof lintChecks)[number];
|
|
7
7
|
declare const configSchema: z.ZodObject<{
|
|
8
8
|
rootFolder: z.ZodString;
|
|
@@ -65,7 +65,7 @@ declare const configSchema: z.ZodObject<{
|
|
|
65
65
|
}, z.core.$strip>]>>>;
|
|
66
66
|
lint: z.ZodOptional<z.ZodRecord<z.ZodEnum<{
|
|
67
67
|
"context-isolation": "context-isolation";
|
|
68
|
-
"shared-
|
|
68
|
+
"shared-kernel": "shared-kernel";
|
|
69
69
|
layers: "layers";
|
|
70
70
|
dependencies: "dependencies";
|
|
71
71
|
react: "react";
|
|
@@ -67,7 +67,7 @@ export declare const defaultDependencyRules: DependencyRules;
|
|
|
67
67
|
export declare const wiredModuleKind: (wiringKind: string) => "repositories" | "domain-services" | "application-ports" | "application-services" | "use-cases" | "commands" | "queries" | "infrastructure-services" | "presentation-services" | undefined;
|
|
68
68
|
/**
|
|
69
69
|
* The kind of a module file, from its path inside a context or the
|
|
70
|
-
* Shared
|
|
70
|
+
* Shared Kernel (`application/use-cases/…`), or undefined for other files
|
|
71
71
|
* such as entities, value objects and errors.
|
|
72
72
|
*/
|
|
73
73
|
export declare const fileModuleKind: (segments: string[]) => ModuleKind | undefined;
|
package/dist/file-system.d.ts
CHANGED
|
@@ -2,6 +2,11 @@
|
|
|
2
2
|
* Existing files a full rewrite would replace, whatever their content.
|
|
3
3
|
*/
|
|
4
4
|
export declare const filesToOverwrite: () => string[];
|
|
5
|
+
/**
|
|
6
|
+
* Runs a generator that only adds files: its rewrites of files that
|
|
7
|
+
* already exist on disk are dropped, so files edited by the user stay.
|
|
8
|
+
*/
|
|
9
|
+
export declare const withoutOverwrites: <T>(generate: () => T) => T;
|
|
5
10
|
export declare const discardPendingChanges: () => void;
|
|
6
11
|
export declare const writePendingChanges: () => void;
|
|
7
12
|
declare class FileSystemItem {
|
package/dist/in-memory-db.d.ts
CHANGED
|
@@ -5,6 +5,11 @@ import { type WiredModule } from './wiring';
|
|
|
5
5
|
* The shared in-memory DB with its spec and wire, as the config says.
|
|
6
6
|
*/
|
|
7
7
|
export declare const scaffoldInMemoryDb: (shared: Folder) => void;
|
|
8
|
+
/**
|
|
9
|
+
* Whether the files of the in-memory DB are there, its wire included
|
|
10
|
+
* with wiring.
|
|
11
|
+
*/
|
|
12
|
+
export declare const inMemoryDbScaffolded: () => boolean;
|
|
8
13
|
/**
|
|
9
14
|
* Whether implementations of this type get the in-memory DB: it is
|
|
10
15
|
* enabled in the config and its files are there.
|