ddd-ts-kit 0.1.1 → 0.2.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 +81 -21
- package/dist/alias/compiler-resolution-of.d.ts +10 -0
- package/dist/alias/compiler-resolution-of.d.ts.map +1 -0
- package/dist/alias/compiler-resolution-of.js +13 -0
- package/dist/alias/compiler-resolution-of.js.map +1 -0
- package/dist/alias/compiler-resolution.d.ts +8 -0
- package/dist/alias/compiler-resolution.d.ts.map +1 -0
- package/dist/alias/compiler-resolution.js +2 -0
- package/dist/alias/compiler-resolution.js.map +1 -0
- package/dist/alias/index.d.ts +3 -1
- package/dist/alias/index.d.ts.map +1 -1
- package/dist/alias/index.js +3 -1
- package/dist/alias/index.js.map +1 -1
- package/dist/alias/module-name-mapper.d.ts +4 -3
- package/dist/alias/module-name-mapper.d.ts.map +1 -1
- package/dist/alias/module-name-mapper.js +6 -4
- package/dist/alias/module-name-mapper.js.map +1 -1
- package/dist/alias/specifier-of.d.ts +7 -0
- package/dist/alias/specifier-of.d.ts.map +1 -0
- package/dist/alias/specifier-of.js +17 -0
- package/dist/alias/specifier-of.js.map +1 -0
- package/dist/alias/specifier-suffix.d.ts +6 -0
- package/dist/alias/specifier-suffix.d.ts.map +1 -0
- package/dist/alias/specifier-suffix.js +8 -0
- package/dist/alias/specifier-suffix.js.map +1 -0
- package/dist/alias/to-alias.d.ts +3 -2
- package/dist/alias/to-alias.d.ts.map +1 -1
- package/dist/alias/to-alias.js +4 -3
- package/dist/alias/to-alias.js.map +1 -1
- package/dist/build/emitted-place.d.ts +2 -0
- package/dist/build/emitted-place.d.ts.map +1 -1
- package/dist/build/emitted-specifier.d.ts +3 -2
- package/dist/build/emitted-specifier.d.ts.map +1 -1
- package/dist/build/emitted-specifier.js +6 -12
- package/dist/build/emitted-specifier.js.map +1 -1
- package/dist/build/emitted-target.d.ts +9 -0
- package/dist/build/emitted-target.d.ts.map +1 -0
- package/dist/build/emitted-target.js +18 -0
- package/dist/build/emitted-target.js.map +1 -0
- package/dist/build/rewrite-aliases.d.ts +5 -3
- package/dist/build/rewrite-aliases.d.ts.map +1 -1
- package/dist/build/rewrite-aliases.js +12 -7
- package/dist/build/rewrite-aliases.js.map +1 -1
- package/dist/build/rewrite-specifiers.d.ts +3 -1
- package/dist/build/rewrite-specifiers.d.ts.map +1 -1
- package/dist/build/rewrite-specifiers.js +2 -2
- package/dist/build/rewrite-specifiers.js.map +1 -1
- package/dist/build/unresolved-problem.d.ts +4 -0
- package/dist/build/unresolved-problem.d.ts.map +1 -0
- package/dist/build/unresolved-problem.js +16 -0
- package/dist/build/unresolved-problem.js.map +1 -0
- package/dist/check/alias/compiler-resolution.d.ts +10 -0
- package/dist/check/alias/compiler-resolution.d.ts.map +1 -0
- package/dist/check/alias/compiler-resolution.js +47 -0
- package/dist/check/alias/compiler-resolution.js.map +1 -0
- package/dist/check/alias/test-runners.js +4 -4
- package/dist/check/alias/test-runners.js.map +1 -1
- package/dist/check/canonical/roles.d.ts.map +1 -1
- package/dist/check/canonical/roles.js +6 -0
- package/dist/check/canonical/roles.js.map +1 -1
- package/dist/check/catalogue/architecture-rules.d.ts.map +1 -1
- package/dist/check/catalogue/architecture-rules.js +4 -0
- package/dist/check/catalogue/architecture-rules.js.map +1 -1
- package/dist/check/configuration/config-inspection.d.ts +2 -0
- package/dist/check/configuration/config-inspection.d.ts.map +1 -1
- package/dist/check/configuration/config-inspection.js +11 -1
- package/dist/check/configuration/config-inspection.js.map +1 -1
- package/dist/check/declarations/classes-of.js +1 -1
- package/dist/check/declarations/classes-of.js.map +1 -1
- package/dist/check/explain/context-docs.js +7 -7
- package/dist/check/explain/context-docs.js.map +1 -1
- package/dist/check/explain/imports-docs.d.ts.map +1 -1
- package/dist/check/explain/imports-docs.js +24 -9
- package/dist/check/explain/imports-docs.js.map +1 -1
- package/dist/check/explain/layer-docs.js +7 -7
- package/dist/check/explain/layer-docs.js.map +1 -1
- package/dist/check/explain/ports-docs.d.ts.map +1 -1
- package/dist/check/explain/ports-docs.js +15 -7
- package/dist/check/explain/ports-docs.js.map +1 -1
- package/dist/check/explain/scheduling-docs.js +1 -1
- package/dist/check/explain/wiring-docs.d.ts.map +1 -1
- package/dist/check/explain/wiring-docs.js +35 -10
- package/dist/check/explain/wiring-docs.js.map +1 -1
- package/dist/check/fixtures/alias-declared-fixtures.d.ts.map +1 -1
- package/dist/check/fixtures/alias-declared-fixtures.js +32 -1
- package/dist/check/fixtures/alias-declared-fixtures.js.map +1 -1
- package/dist/check/fixtures/config-fixtures.d.ts.map +1 -1
- package/dist/check/fixtures/config-fixtures.js +6 -0
- package/dist/check/fixtures/config-fixtures.js.map +1 -1
- package/dist/check/fixtures/constructor-injection-fixtures.d.ts +3 -0
- package/dist/check/fixtures/constructor-injection-fixtures.d.ts.map +1 -0
- package/dist/check/fixtures/constructor-injection-fixtures.js +111 -0
- package/dist/check/fixtures/constructor-injection-fixtures.js.map +1 -0
- package/dist/check/fixtures/declared-project.d.ts.map +1 -1
- package/dist/check/fixtures/declared-project.js +4 -1
- package/dist/check/fixtures/declared-project.js.map +1 -1
- package/dist/check/fixtures/extension-fixtures.d.ts +3 -0
- package/dist/check/fixtures/extension-fixtures.d.ts.map +1 -0
- package/dist/check/fixtures/extension-fixtures.js +77 -0
- package/dist/check/fixtures/extension-fixtures.js.map +1 -0
- package/dist/check/fixtures/fixtures.d.ts.map +1 -1
- package/dist/check/fixtures/fixtures.js +4 -0
- package/dist/check/fixtures/fixtures.js.map +1 -1
- package/dist/check/fixtures/signature-project.d.ts +11 -0
- package/dist/check/fixtures/signature-project.d.ts.map +1 -0
- package/dist/check/fixtures/signature-project.js +21 -0
- package/dist/check/fixtures/signature-project.js.map +1 -0
- package/dist/check/fixtures/signature.d.ts +13 -0
- package/dist/check/fixtures/signature.d.ts.map +1 -0
- package/dist/check/fixtures/signature.js +24 -0
- package/dist/check/fixtures/signature.js.map +1 -0
- package/dist/check/project/beside-the-sources.d.ts +5 -0
- package/dist/check/project/beside-the-sources.d.ts.map +1 -0
- package/dist/check/project/beside-the-sources.js +21 -0
- package/dist/check/project/beside-the-sources.js.map +1 -0
- package/dist/check/project/resolve-import.d.ts.map +1 -1
- package/dist/check/project/resolve-import.js +4 -1
- package/dist/check/project/resolve-import.js.map +1 -1
- package/dist/check/rules/clean-one-export-per-file.d.ts.map +1 -1
- package/dist/check/rules/clean-one-export-per-file.js +14 -8
- package/dist/check/rules/clean-one-export-per-file.js.map +1 -1
- package/dist/check/rules/config-valid.d.ts.map +1 -1
- package/dist/check/rules/config-valid.js +2 -1
- package/dist/check/rules/config-valid.js.map +1 -1
- package/dist/check/rules/declarations-barrel-current.d.ts.map +1 -1
- package/dist/check/rules/declarations-barrel-current.js +34 -32
- package/dist/check/rules/declarations-barrel-current.js.map +1 -1
- package/dist/check/rules/declarations-constructor-injection.d.ts +3 -0
- package/dist/check/rules/declarations-constructor-injection.d.ts.map +1 -0
- package/dist/check/rules/declarations-constructor-injection.js +58 -0
- package/dist/check/rules/declarations-constructor-injection.js.map +1 -0
- package/dist/check/rules/imports-alias-declared.d.ts.map +1 -1
- package/dist/check/rules/imports-alias-declared.js +3 -1
- package/dist/check/rules/imports-alias-declared.js.map +1 -1
- package/dist/check/rules/imports-alias-only.d.ts.map +1 -1
- package/dist/check/rules/imports-alias-only.js +16 -29
- package/dist/check/rules/imports-alias-only.js.map +1 -1
- package/dist/check/rules/imports-extension.d.ts +3 -0
- package/dist/check/rules/imports-extension.d.ts.map +1 -0
- package/dist/check/rules/imports-extension.js +65 -0
- package/dist/check/rules/imports-extension.js.map +1 -0
- package/dist/check/rules/ports-no-concrete-dependency.d.ts.map +1 -1
- package/dist/check/rules/ports-no-concrete-dependency.js +43 -15
- package/dist/check/rules/ports-no-concrete-dependency.js.map +1 -1
- package/dist/check/rules/tree-closed.js +6 -4
- package/dist/check/rules/tree-closed.js.map +1 -1
- package/dist/commands/build-aliases.d.ts.map +1 -1
- package/dist/commands/build-aliases.js +5 -3
- package/dist/commands/build-aliases.js.map +1 -1
- package/dist/commands/docs.d.ts.map +1 -1
- package/dist/commands/docs.js +17 -2
- package/dist/commands/docs.js.map +1 -1
- package/dist/commands/init.d.ts.map +1 -1
- package/dist/commands/init.js +5 -4
- package/dist/commands/init.js.map +1 -1
- package/dist/commit/is-derived.d.ts.map +1 -1
- package/dist/commit/is-derived.js +5 -2
- package/dist/commit/is-derived.js.map +1 -1
- package/dist/config/config.d.ts +2 -0
- package/dist/config/config.d.ts.map +1 -1
- package/dist/config/default-import-extension.d.ts +3 -0
- package/dist/config/default-import-extension.d.ts.map +1 -0
- package/dist/config/default-import-extension.js +3 -0
- package/dist/config/default-import-extension.js.map +1 -0
- package/dist/config/import-extensions.d.ts +3 -0
- package/dist/config/import-extensions.d.ts.map +1 -0
- package/dist/config/import-extensions.js +3 -0
- package/dist/config/import-extensions.js.map +1 -0
- package/dist/config/index.d.ts +4 -1
- package/dist/config/index.d.ts.map +1 -1
- package/dist/config/index.js +4 -1
- package/dist/config/index.js.map +1 -1
- package/dist/config/parse-config.d.ts.map +1 -1
- package/dist/config/parse-config.js +2 -0
- package/dist/config/parse-config.js.map +1 -1
- package/dist/config/parse-stack.d.ts.map +1 -1
- package/dist/config/parse-stack.js +2 -1
- package/dist/config/parse-stack.js.map +1 -1
- package/dist/config/restack-config-text.d.ts +11 -0
- package/dist/config/restack-config-text.d.ts.map +1 -0
- package/dist/config/restack-config-text.js +31 -0
- package/dist/config/restack-config-text.js.map +1 -0
- package/dist/config/serialize-config.d.ts.map +1 -1
- package/dist/config/serialize-config.js +3 -6
- package/dist/config/serialize-config.js.map +1 -1
- package/dist/config/stack.d.ts +8 -0
- package/dist/config/stack.d.ts.map +1 -1
- package/dist/config/stack.js +1 -0
- package/dist/config/stack.js.map +1 -1
- package/dist/config/unwritten-import-extension.d.ts +3 -0
- package/dist/config/unwritten-import-extension.d.ts.map +1 -0
- package/dist/config/unwritten-import-extension.js +3 -0
- package/dist/config/unwritten-import-extension.js.map +1 -0
- package/dist/config/written-stack.d.ts +8 -0
- package/dist/config/written-stack.d.ts.map +1 -0
- package/dist/config/written-stack.js +10 -0
- package/dist/config/written-stack.js.map +1 -0
- package/dist/declared/declared-role.d.ts.map +1 -1
- package/dist/declared/declared-role.js +1 -0
- package/dist/declared/declared-role.js.map +1 -1
- package/dist/declared/dependencies-file.d.ts +7 -0
- package/dist/declared/dependencies-file.d.ts.map +1 -0
- package/dist/declared/dependencies-file.js +9 -0
- package/dist/declared/dependencies-file.js.map +1 -0
- package/dist/declared/generated-drift.d.ts +7 -0
- package/dist/declared/generated-drift.d.ts.map +1 -0
- package/dist/declared/generated-drift.js +47 -0
- package/dist/declared/generated-drift.js.map +1 -0
- package/dist/declared/index.d.ts +8 -1
- package/dist/declared/index.d.ts.map +1 -1
- package/dist/declared/index.js +6 -1
- package/dist/declared/index.js.map +1 -1
- package/dist/declared/injection/class-injection.d.ts +19 -0
- package/dist/declared/injection/class-injection.d.ts.map +1 -0
- package/dist/declared/injection/class-injection.js +2 -0
- package/dist/declared/injection/class-injection.js.map +1 -0
- package/dist/declared/injection/constructor-of.d.ts +16 -0
- package/dist/declared/injection/constructor-of.d.ts.map +1 -0
- package/dist/declared/injection/constructor-of.js +33 -0
- package/dist/declared/injection/constructor-of.js.map +1 -0
- package/dist/declared/injection/context-injections.d.ts +8 -0
- package/dist/declared/injection/context-injections.d.ts.map +1 -0
- package/dist/declared/injection/context-injections.js +14 -0
- package/dist/declared/injection/context-injections.js.map +1 -0
- package/dist/declared/injection/declared-kind-of.d.ts +8 -0
- package/dist/declared/injection/declared-kind-of.d.ts.map +1 -0
- package/dist/declared/injection/declared-kind-of.js +12 -0
- package/dist/declared/injection/declared-kind-of.js.map +1 -0
- package/dist/declared/injection/exported-name-of.d.ts +4 -0
- package/dist/declared/injection/exported-name-of.d.ts.map +1 -0
- package/dist/declared/injection/exported-name-of.js +17 -0
- package/dist/declared/injection/exported-name-of.js.map +1 -0
- package/dist/declared/injection/language-types.d.ts +3 -0
- package/dist/declared/injection/language-types.d.ts.map +1 -0
- package/dist/declared/injection/language-types.js +32 -0
- package/dist/declared/injection/language-types.js.map +1 -0
- package/dist/declared/injection/local-names.d.ts +17 -0
- package/dist/declared/injection/local-names.d.ts.map +1 -0
- package/dist/declared/injection/local-names.js +41 -0
- package/dist/declared/injection/local-names.js.map +1 -0
- package/dist/declared/injection/parameter-shape.d.ts +11 -0
- package/dist/declared/injection/parameter-shape.d.ts.map +1 -0
- package/dist/declared/injection/parameter-shape.js +58 -0
- package/dist/declared/injection/parameter-shape.js.map +1 -0
- package/dist/declared/injection/raw-class-name.d.ts +7 -0
- package/dist/declared/injection/raw-class-name.d.ts.map +1 -0
- package/dist/declared/injection/raw-class-name.js +28 -0
- package/dist/declared/injection/raw-class-name.js.map +1 -0
- package/dist/declared/injection/read-constructor.d.ts +10 -0
- package/dist/declared/injection/read-constructor.d.ts.map +1 -0
- package/dist/declared/injection/read-constructor.js +2 -0
- package/dist/declared/injection/read-constructor.js.map +1 -0
- package/dist/declared/injection/read-injections.d.ts +6 -0
- package/dist/declared/injection/read-injections.d.ts.map +1 -0
- package/dist/declared/injection/read-injections.js +75 -0
- package/dist/declared/injection/read-injections.js.map +1 -0
- package/dist/declared/injection/render-injections.d.ts +11 -0
- package/dist/declared/injection/render-injections.d.ts.map +1 -0
- package/dist/declared/injection/render-injections.js +51 -0
- package/dist/declared/injection/render-injections.js.map +1 -0
- package/dist/declared/injection/rendered-injections.d.ts +8 -0
- package/dist/declared/injection/rendered-injections.d.ts.map +1 -0
- package/dist/declared/injection/rendered-injections.js +2 -0
- package/dist/declared/injection/rendered-injections.js.map +1 -0
- package/dist/declared/injection/resolve-token.d.ts +18 -0
- package/dist/declared/injection/resolve-token.d.ts.map +1 -0
- package/dist/declared/injection/resolve-token.js +46 -0
- package/dist/declared/injection/resolve-token.js.map +1 -0
- package/dist/declared/injection/resolved-token.d.ts +10 -0
- package/dist/declared/injection/resolved-token.d.ts.map +1 -0
- package/dist/declared/injection/resolved-token.js +2 -0
- package/dist/declared/injection/resolved-token.js.map +1 -0
- package/dist/declared/injection/sources.d.ts +4 -0
- package/dist/declared/injection/sources.d.ts.map +1 -0
- package/dist/declared/injection/sources.js +2 -0
- package/dist/declared/injection/sources.js.map +1 -0
- package/dist/declared/injection/token-reference.d.ts +14 -0
- package/dist/declared/injection/token-reference.d.ts.map +1 -0
- package/dist/declared/injection/token-reference.js +2 -0
- package/dist/declared/injection/token-reference.js.map +1 -0
- package/dist/declared/render-barrel.d.ts +8 -5
- package/dist/declared/render-barrel.d.ts.map +1 -1
- package/dist/declared/render-barrel.js +13 -6
- package/dist/declared/render-barrel.js.map +1 -1
- package/dist/declared/render-dependencies-file.d.ts +8 -0
- package/dist/declared/render-dependencies-file.d.ts.map +1 -0
- package/dist/declared/render-dependencies-file.js +12 -0
- package/dist/declared/render-dependencies-file.js.map +1 -0
- package/dist/depcruise/hygiene-rules.js +2 -1
- package/dist/depcruise/hygiene-rules.js.map +1 -1
- package/dist/describe/context-description.d.ts +10 -0
- package/dist/describe/context-description.d.ts.map +1 -1
- package/dist/describe/describe-context.d.ts.map +1 -1
- package/dist/describe/describe-context.js +2 -0
- package/dist/describe/describe-context.js.map +1 -1
- package/dist/describe/format-description.d.ts.map +1 -1
- package/dist/describe/format-description.js +4 -0
- package/dist/describe/format-description.js.map +1 -1
- package/dist/describe/read-projections.d.ts +5 -0
- package/dist/describe/read-projections.d.ts.map +1 -0
- package/dist/describe/read-projections.js +19 -0
- package/dist/describe/read-projections.js.map +1 -0
- package/dist/describe/reference-lines.js +9 -0
- package/dist/describe/reference-lines.js.map +1 -1
- package/dist/dev/refresh-declarations.d.ts +9 -0
- package/dist/dev/refresh-declarations.d.ts.map +1 -0
- package/dist/dev/refresh-declarations.js +28 -0
- package/dist/dev/refresh-declarations.js.map +1 -0
- package/dist/generate/access-vars.js +3 -3
- package/dist/generate/access-vars.js.map +1 -1
- package/dist/generate/kinds/context-plan.d.ts +10 -0
- package/dist/generate/kinds/context-plan.d.ts.map +1 -0
- package/dist/generate/kinds/context-plan.js +2 -0
- package/dist/generate/kinds/context-plan.js.map +1 -0
- package/dist/generate/kinds/declare-context-entries.d.ts +3 -1
- package/dist/generate/kinds/declare-context-entries.d.ts.map +1 -1
- package/dist/generate/kinds/declare-context-entries.js +4 -2
- package/dist/generate/kinds/declare-context-entries.js.map +1 -1
- package/dist/generate/kinds/extraction/service-selection.js +8 -11
- package/dist/generate/kinds/extraction/service-selection.js.map +1 -1
- package/dist/generate/kinds/job/job-vars.d.ts.map +1 -1
- package/dist/generate/kinds/job/job-vars.js +5 -3
- package/dist/generate/kinds/job/job-vars.js.map +1 -1
- package/dist/generate/kinds/plan-vars.d.ts +5 -0
- package/dist/generate/kinds/plan-vars.d.ts.map +1 -0
- package/dist/generate/kinds/plan-vars.js +24 -0
- package/dist/generate/kinds/plan-vars.js.map +1 -0
- package/dist/generate/kinds/projection-kind.d.ts +3 -0
- package/dist/generate/kinds/projection-kind.d.ts.map +1 -0
- package/dist/generate/kinds/projection-kind.js +72 -0
- package/dist/generate/kinds/projection-kind.js.map +1 -0
- package/dist/generate/kinds/publish-in-index.js +2 -2
- package/dist/generate/kinds/publish-in-index.js.map +1 -1
- package/dist/generate/kinds/route/route-vars.d.ts.map +1 -1
- package/dist/generate/kinds/route/route-vars.js +7 -6
- package/dist/generate/kinds/route/route-vars.js.map +1 -1
- package/dist/generate/kinds/wire-context.d.ts +10 -0
- package/dist/generate/kinds/wire-context.d.ts.map +1 -0
- package/dist/generate/kinds/wire-context.js +36 -0
- package/dist/generate/kinds/wire-context.js.map +1 -0
- package/dist/generate/kinds/write-context-files.d.ts +1 -8
- package/dist/generate/kinds/write-context-files.d.ts.map +1 -1
- package/dist/generate/kinds/write-context-files.js +3 -40
- package/dist/generate/kinds/write-context-files.js.map +1 -1
- package/dist/generate/kinds.d.ts.map +1 -1
- package/dist/generate/kinds.js +2 -0
- package/dist/generate/kinds.js.map +1 -1
- package/dist/generate/refresh-barrels.d.ts +4 -3
- package/dist/generate/refresh-barrels.d.ts.map +1 -1
- package/dist/generate/refresh-barrels.js +41 -16
- package/dist/generate/refresh-barrels.js.map +1 -1
- package/dist/generate/spec-vars.js +4 -4
- package/dist/generate/spec-vars.js.map +1 -1
- package/dist/generate/storage-vars.d.ts +2 -2
- package/dist/generate/storage-vars.d.ts.map +1 -1
- package/dist/generate/storage-vars.js +6 -10
- package/dist/generate/storage-vars.js.map +1 -1
- package/dist/generate/workspace-sources.d.ts +6 -0
- package/dist/generate/workspace-sources.d.ts.map +1 -0
- package/dist/generate/workspace-sources.js +13 -0
- package/dist/generate/workspace-sources.js.map +1 -0
- package/dist/init/manifest/scripts-for.js +6 -1
- package/dist/init/manifest/scripts-for.js.map +1 -1
- package/dist/init/manifest/versions.js +23 -23
- package/dist/init/run-init.d.ts.map +1 -1
- package/dist/init/run-init.js +32 -3
- package/dist/init/run-init.js.map +1 -1
- package/dist/init/stack/recorded-options.d.ts +11 -0
- package/dist/init/stack/recorded-options.d.ts.map +1 -0
- package/dist/init/stack/recorded-options.js +19 -0
- package/dist/init/stack/recorded-options.js.map +1 -0
- package/dist/init/stack/resolve-stack.d.ts +6 -1
- package/dist/init/stack/resolve-stack.d.ts.map +1 -1
- package/dist/init/stack/resolve-stack.js +46 -9
- package/dist/init/stack/resolve-stack.js.map +1 -1
- package/dist/init/stack/resolve-style.d.ts +3 -5
- package/dist/init/stack/resolve-style.d.ts.map +1 -1
- package/dist/init/stack/resolve-style.js +11 -3
- package/dist/init/stack/resolve-style.js.map +1 -1
- package/dist/init/stack/stack-options.d.ts +3 -0
- package/dist/init/stack/stack-options.d.ts.map +1 -1
- package/dist/init/write-agent-settings.js +4 -3
- package/dist/init/write-agent-settings.js.map +1 -1
- package/dist/init/write-type-script-configs.d.ts +2 -1
- package/dist/init/write-type-script-configs.d.ts.map +1 -1
- package/dist/init/write-type-script-configs.js +4 -4
- package/dist/init/write-type-script-configs.js.map +1 -1
- package/dist/refresh-declarations.d.ts +3 -0
- package/dist/refresh-declarations.d.ts.map +1 -0
- package/dist/refresh-declarations.js +4 -0
- package/dist/refresh-declarations.js.map +1 -0
- package/dist/run.d.ts.map +1 -1
- package/dist/run.js +2 -0
- package/dist/run.js.map +1 -1
- package/dist/stack/alias-vars.d.ts +2 -1
- package/dist/stack/alias-vars.d.ts.map +1 -1
- package/dist/stack/alias-vars.js +6 -3
- package/dist/stack/alias-vars.js.map +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +4 -3
- package/templates/acl/translator.spec.ts.tpl +1 -1
- package/templates/adapter/adapter.declared.ts.tpl +3 -3
- package/templates/adapter/adapter.spec.ts.tpl +1 -1
- package/templates/adapter/adapter.ts.tpl +1 -1
- package/templates/adapter/wiring.tsyringe.tpl +3 -3
- package/templates/aggregate/aggregate.spec.ts.tpl +2 -2
- package/templates/architecture/extractable.declared.spec.ts.tpl +1 -1
- package/templates/architecture/extractable.manual.spec.ts.tpl +4 -4
- package/templates/architecture/extractable.tsyringe.spec.ts.tpl +1 -1
- package/templates/architecture/wiring.declared.tpl +1 -1
- package/templates/architecture/wiring.manual.tpl +1 -1
- package/templates/architecture/wiring.tsyringe.tpl +1 -1
- package/templates/builder/builder.ts.tpl +1 -1
- package/templates/command/handler.declared.ts.tpl +7 -7
- package/templates/command/handler.spec.buses.ts.tpl +4 -4
- package/templates/command/handler.spec.tsyringe.ts.tpl +5 -5
- package/templates/command/handler.ts.tpl +4 -4
- package/templates/command/wiring.manual.tpl +2 -2
- package/templates/command/wiring.tsyringe.tpl +3 -3
- package/templates/context/module.manual.ts.tpl +1 -1
- package/templates/context/permission-set.tpl +1 -1
- package/templates/context/permissions.spec.ts.tpl +1 -1
- package/templates/context/routes.spec.ts.tpl +1 -1
- package/templates/context/wiring.declared.tpl +2 -2
- package/templates/context/wiring.manual.tpl +1 -1
- package/templates/context/wiring.tsyringe.tpl +2 -2
- package/templates/domain-error/domain-error.spec.ts.tpl +1 -1
- package/templates/domain-event/domain-event.spec.ts.tpl +1 -1
- package/templates/domain-service/domain-service.spec.ts.tpl +1 -1
- package/templates/e2e/e2e.spec.ts.tpl +2 -2
- package/templates/entity/entity.spec.ts.tpl +1 -1
- package/templates/event-handler/event-handler.declared.ts.tpl +3 -3
- package/templates/event-handler/event-handler.spec.ts.tpl +2 -2
- package/templates/event-handler/event-handler.ts.tpl +1 -1
- package/templates/event-handler/wiring.manual.tpl +2 -2
- package/templates/event-handler/wiring.tsyringe.tpl +2 -2
- package/templates/gateway/adapter.declared.ts.tpl +3 -3
- package/templates/gateway/adapter.ts.tpl +2 -2
- package/templates/gateway/contract.spec.ts.tpl +3 -3
- package/templates/gateway/fake.ts.tpl +1 -1
- package/templates/gateway/platform-test.declared.tpl +1 -1
- package/templates/gateway/platform.declared.tpl +1 -1
- package/templates/gateway/wiring.tsyringe.tpl +3 -3
- package/templates/init/CLAUDE.md.tpl +5 -2
- package/templates/init/README.md.tpl +15 -10
- package/templates/init/e2e/create-credentials.jwt.ts.tpl +1 -1
- package/templates/init/e2e/create-credentials.keycloak.ts.tpl +1 -1
- package/templates/init/e2e/create-credentials.none.ts.tpl +2 -2
- package/templates/init/e2e/start-application.database.ts.tpl +16 -16
- package/templates/init/e2e/start-application.memory.ts.tpl +16 -16
- package/templates/init/e2e/test-environment.ts.tpl +1 -1
- package/templates/init/main.ts.tpl +11 -11
- package/templates/init/platform/audit/audit.module.manual.ts.tpl +5 -5
- package/templates/init/platform/audit/audit.module.tsyringe.ts.tpl +4 -4
- package/templates/init/platform/audit/create-audit.ts.tpl +5 -5
- package/templates/init/platform/audit/search-audit-entries.handler.ts.tpl +1 -1
- package/templates/init/platform/audit/search-audit-entries.route.ts.tpl +1 -1
- package/templates/init/platform/auth/authorization.tsyringe.ts.tpl +2 -2
- package/templates/init/platform/auth/create-authenticator.jwt.ts.tpl +1 -1
- package/templates/init/platform/auth/create-authenticator.keycloak.ts.tpl +1 -1
- package/templates/init/platform/auth/create-authenticator.none.ts.tpl +2 -2
- package/templates/init/platform/auth/create-authorizer.abac.ts.tpl +1 -1
- package/templates/init/platform/auth/create-authorizer.custom.ts.tpl +2 -2
- package/templates/init/platform/auth/create-authorizer.rbac.ts.tpl +1 -1
- package/templates/init/platform/auth/create-authorizer.rebac.ts.tpl +3 -3
- package/templates/init/platform/auth/create-tuple-store.contract.spec.ts.tpl +1 -1
- package/templates/init/platform/auth/custom-authorizer.contract.spec.ts.tpl +1 -1
- package/templates/init/platform/auth/http-boundary.ts.tpl +1 -1
- package/templates/init/platform/auth/permission-mapping.ts.tpl +1 -1
- package/templates/init/platform/auth/permissions.ts.tpl +1 -1
- package/templates/init/platform/auth/principal-of.none.ts.tpl +1 -1
- package/templates/init/platform/auth/relate-system-actors.ts.tpl +1 -1
- package/templates/init/platform/auth/relation-tuples.ts.tpl +2 -2
- package/templates/init/platform/auth/security-schemes.none.ts.tpl +1 -1
- package/templates/init/platform/buses/create-command-bus.ts.tpl +2 -2
- package/templates/init/platform/buses/create-query-bus.ts.tpl +1 -1
- package/templates/init/platform/compose-application.manual.ts.tpl +6 -6
- package/templates/init/platform/compose-application.tsyringe.ts.tpl +10 -10
- package/templates/init/platform/config/app-config.ts.tpl +2 -2
- package/templates/init/platform/config/load-config.ts.tpl +3 -3
- package/templates/init/platform/create-platform.manual.ts.tpl +16 -16
- package/templates/init/platform/database/create-client.prisma.ts.tpl +1 -1
- package/templates/init/platform/database/create-data-source.typeorm.ts.tpl +1 -1
- package/templates/init/platform/database/data-source.typeorm.ts.tpl +1 -1
- package/templates/init/platform/database/database.drizzle.ts.tpl +1 -1
- package/templates/init/platform/database/database.prisma.ts.tpl +2 -2
- package/templates/init/platform/database/inert-persistence.memory.ts.tpl +2 -2
- package/templates/init/platform/database/inert-persistence.pooled.ts.tpl +2 -2
- package/templates/init/platform/database/inert-persistence.prisma.ts.tpl +3 -3
- package/templates/init/platform/database/inert-persistence.typeorm.ts.tpl +3 -3
- package/templates/init/platform/database/open-persistence.contract.spec.ts.tpl +1 -1
- package/templates/init/platform/database/open-persistence.memory.ts.tpl +1 -1
- package/templates/init/platform/database/open-persistence.pooled.ts.tpl +3 -3
- package/templates/init/platform/database/open-persistence.prisma.ts.tpl +3 -3
- package/templates/init/platform/database/open-persistence.typeorm.ts.tpl +3 -3
- package/templates/init/platform/database/open-test-database.drizzle.ts.tpl +4 -4
- package/templates/init/platform/database/open-test-database.knex.ts.tpl +5 -5
- package/templates/init/platform/database/open-test-database.prisma.ts.tpl +4 -4
- package/templates/init/platform/database/open-test-database.typeorm.ts.tpl +3 -3
- package/templates/init/platform/database/persistence-over.drizzle.ts.tpl +2 -2
- package/templates/init/platform/database/persistence-over.knex.ts.tpl +2 -2
- package/templates/init/platform/database/persistence-over.prisma.ts.tpl +2 -2
- package/templates/init/platform/database/persistence-over.typeorm.ts.tpl +2 -2
- package/templates/init/platform/database/persistence.orm.ts.tpl +1 -1
- package/templates/init/platform/errors.ts.tpl +1 -1
- package/templates/init/platform/events/create-event-provider.custom.ts.tpl +2 -2
- package/templates/init/platform/events/create-event-provider.kafka.ts.tpl +3 -3
- package/templates/init/platform/events/create-event-provider.nats.ts.tpl +2 -2
- package/templates/init/platform/events/create-event-provider.rabbitmq.ts.tpl +2 -2
- package/templates/init/platform/events/create-event-provider.redis.ts.tpl +2 -2
- package/templates/init/platform/events/custom-event-bus.contract.spec.ts.tpl +1 -1
- package/templates/init/platform/events/in-process-events.ts.tpl +1 -1
- package/templates/init/platform/events/start-outbox-relay.ts.tpl +1 -1
- package/templates/init/platform/http/create-app-module.ts.tpl +1 -1
- package/templates/init/platform/http/start-http-server.express.ts.tpl +4 -4
- package/templates/init/platform/http/start-http-server.fastify.ts.tpl +4 -4
- package/templates/init/platform/http/start-http-server.nest.ts.tpl +5 -5
- package/templates/init/platform/http/with-documentation.ts.tpl +2 -2
- package/templates/init/platform/lay-foundations.tsyringe.ts.tpl +5 -5
- package/templates/init/platform/platform-test.module.tsyringe.ts.tpl +1 -1
- package/templates/init/platform/platform.manual.ts.tpl +3 -3
- package/templates/init/platform/platform.module.tsyringe.ts.tpl +8 -8
- package/templates/init/platform/resilience/adapter-aspects.ts.tpl +2 -2
- package/templates/init/platform/resilience/default-resilience.ts.tpl +1 -1
- package/templates/init/platform/resilience/own-policy.ts.tpl +1 -1
- package/templates/init/platform/tracing.ts.tpl +2 -2
- package/templates/init/rules/application.md.tpl +8 -2
- package/templates/init/rules/infrastructure.md.tpl +3 -3
- package/templates/init/scripts/openapi.ts.tpl +5 -5
- package/templates/integration-event/audited.tpl +1 -1
- package/templates/integration-event/integration-event.class-validator.ts.tpl +1 -1
- package/templates/integration-event/integration-event.custom.ts.tpl +1 -1
- package/templates/integration-event/publisher.declared.ts.tpl +4 -4
- package/templates/integration-event/publisher.spec.ts.tpl +2 -2
- package/templates/integration-event/publisher.ts.tpl +2 -2
- package/templates/integration-event/wiring.manual.tpl +2 -2
- package/templates/integration-event/wiring.tsyringe.tpl +2 -2
- package/templates/integration-handler/integration-handler.declared.ts.tpl +3 -3
- package/templates/integration-handler/integration-handler.spec.ts.tpl +2 -2
- package/templates/integration-handler/integration-handler.ts.tpl +1 -1
- package/templates/integration-handler/wiring.manual.tpl +3 -3
- package/templates/integration-handler/wiring.tsyringe.tpl +2 -2
- package/templates/job/job.declared.ts.tpl +3 -3
- package/templates/job/job.spec.buses.ts.tpl +2 -2
- package/templates/job/job.spec.tsyringe.ts.tpl +2 -2
- package/templates/job/job.ts.tpl +1 -1
- package/templates/job/wiring.manual.tpl +1 -1
- package/templates/job/wiring.tsyringe.tpl +1 -1
- package/templates/pipeline/package-scripts.json +1 -1
- package/templates/policy/policy.declared.ts.tpl +1 -1
- package/templates/policy/policy.spec.declared.ts.tpl +1 -1
- package/templates/policy/policy.spec.ts.tpl +1 -1
- package/templates/policy/policy.ts.tpl +1 -1
- package/templates/policy/registration.tpl +1 -1
- package/templates/port/fake.ts.tpl +1 -1
- package/templates/projection/projection.spec.ts.tpl +17 -0
- package/templates/projection/projection.ts.tpl +11 -0
- package/templates/query/handler.declared.ts.tpl +4 -4
- package/templates/query/handler.spec.buses.ts.tpl +5 -5
- package/templates/query/handler.spec.tsyringe.ts.tpl +6 -6
- package/templates/query/handler.ts.tpl +3 -3
- package/templates/query/query.ts.tpl +1 -1
- package/templates/query/reader.fake.ts.tpl +2 -2
- package/templates/query/reader.in-memory.ts.tpl +4 -4
- package/templates/query/reader.port.ts.tpl +2 -2
- package/templates/query/search.handler.declared.ts.tpl +6 -6
- package/templates/query/search.handler.spec.buses.ts.tpl +5 -5
- package/templates/query/search.handler.spec.tsyringe.ts.tpl +6 -6
- package/templates/query/search.handler.ts.tpl +4 -4
- package/templates/query/search.query.ts.tpl +1 -1
- package/templates/query/search.reader.fake.ts.tpl +2 -2
- package/templates/query/search.reader.in-memory.ts.tpl +3 -3
- package/templates/query/search.reader.port.ts.tpl +1 -1
- package/templates/query/search.reader.spec.ts.tpl +2 -2
- package/templates/query/search.wiring.manual.tpl +3 -3
- package/templates/query/search.wiring.tsyringe.tpl +4 -4
- package/templates/query/wiring.manual.tpl +3 -3
- package/templates/query/wiring.tsyringe.tpl +4 -4
- package/templates/repository/contract.spec.ts.tpl +5 -5
- package/templates/repository/drizzle/mapper.ts.tpl +2 -2
- package/templates/repository/drizzle/repository.ts.tpl +9 -17
- package/templates/repository/drizzle/schema-export.tpl +1 -1
- package/templates/repository/fake.ts.tpl +2 -2
- package/templates/repository/knex/mapper.ts.tpl +2 -2
- package/templates/repository/knex/repository.ts.tpl +10 -30
- package/templates/repository/knex/schema-export.tpl +1 -1
- package/templates/repository/knex/tables.ts.tpl +1 -1
- package/templates/repository/none/repository.ts.tpl +3 -3
- package/templates/repository/prisma/mapper.ts.tpl +2 -2
- package/templates/repository/prisma/repository.ts.tpl +6 -9
- package/templates/repository/repository.ts.tpl +1 -1
- package/templates/repository/typeorm/mapper.ts.tpl +2 -2
- package/templates/repository/typeorm/repository.ts.tpl +9 -12
- package/templates/repository/typeorm/schema-export.tpl +1 -1
- package/templates/repository/typeorm/table.tpl +1 -1
- package/templates/repository/wiring.manual.tpl +1 -1
- package/templates/repository/wiring.tsyringe.tpl +2 -2
- package/templates/route/route.search.ts.tpl +1 -1
- package/templates/route/route.spec.ts.tpl +1 -1
- package/templates/route/routes.on-tsyringe.tpl +1 -1
- package/templates/route/wiring.manual.tpl +1 -1
- package/templates/service/main.ts.tpl +11 -11
- package/templates/value-object/value-object.spec.ts.tpl +1 -1
- package/templates/worker/main.ts.tpl +9 -9
- package/dist/alias/platform-alias.d.ts +0 -4
- package/dist/alias/platform-alias.d.ts.map +0 -1
- package/dist/alias/platform-alias.js +0 -7
- package/dist/alias/platform-alias.js.map +0 -1
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
import { CONFIG_FILE } from '../../config/index.js';
|
|
2
|
+
import { config } from './config.js';
|
|
3
|
+
import { project } from './project.js';
|
|
4
|
+
const RULE = 'imports/extension';
|
|
5
|
+
const LOAD_CONFIG = 'src/platform/config/load-config.ts';
|
|
6
|
+
const APP_CONFIG = 'src/platform/config/app-config.ts';
|
|
7
|
+
const SUPPORT = 'test/e2e/support/start-application.ts';
|
|
8
|
+
const JOURNEY = 'test/e2e/journey.e2e.spec.ts';
|
|
9
|
+
const SCRIPT = 'scripts/openapi.ts';
|
|
10
|
+
const INDEX = 'src/platform/config/index.ts';
|
|
11
|
+
const SETTINGS = 'export const appConfig = { port: 3000 };\n';
|
|
12
|
+
const NONE = { [CONFIG_FILE]: config({ importExtension: 'none' }) };
|
|
13
|
+
const JS = { [CONFIG_FILE]: config({ importExtension: 'js' }) };
|
|
14
|
+
export const EXTENSION_FIXTURES = [
|
|
15
|
+
{
|
|
16
|
+
ruleId: RULE,
|
|
17
|
+
name: 'no extension under "none": a static import, a re-export, a dynamic import, a test and a script; a package subpath that ends like a file is not a project file',
|
|
18
|
+
expect: 'pass',
|
|
19
|
+
files: project({
|
|
20
|
+
[APP_CONFIG]: SETTINGS,
|
|
21
|
+
[INDEX]: "export { appConfig } from '@/platform/config/app-config';\n",
|
|
22
|
+
[LOAD_CONFIG]: [
|
|
23
|
+
"import { core } from 'zod/v4/core.js';",
|
|
24
|
+
"import { appConfig } from '@/platform/config/app-config';",
|
|
25
|
+
"export type { appConfig as Settings } from '@/platform/config/index';",
|
|
26
|
+
"export const later = (): Promise<unknown> => import('@/platform/config/app-config');",
|
|
27
|
+
'export const loaded = [core, appConfig];\n',
|
|
28
|
+
].join('\n'),
|
|
29
|
+
[SUPPORT]: "import { loaded } from '@/platform/config/load-config';\nexport const start = loaded;\n",
|
|
30
|
+
[JOURNEY]: "import { start } from '$test/e2e/support/start-application';\nexport { start };\n",
|
|
31
|
+
[SCRIPT]: "import { loaded } from '@/platform/config/load-config';\nexport { loaded };\n",
|
|
32
|
+
}, NONE),
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
ruleId: RULE,
|
|
36
|
+
name: '".js" under "js", and in a project whose config does not say: it was written before the key existed',
|
|
37
|
+
expect: 'pass',
|
|
38
|
+
files: project({
|
|
39
|
+
[APP_CONFIG]: SETTINGS,
|
|
40
|
+
[LOAD_CONFIG]: "export { appConfig } from '@/platform/config/app-config.js';\n",
|
|
41
|
+
[JOURNEY]: "export { appConfig } from '@/platform/config/app-config.js';\n",
|
|
42
|
+
}),
|
|
43
|
+
},
|
|
44
|
+
failing('".js" under "none"', NONE, [LOAD_CONFIG, "export { appConfig } from '@/platform/config/app-config.js';\n"]),
|
|
45
|
+
failing('".ts" under "none"', NONE, [LOAD_CONFIG, "export { appConfig } from '@/platform/config/app-config.ts';\n"]),
|
|
46
|
+
failing('".mjs" in a dynamic import under "none"', NONE, [
|
|
47
|
+
LOAD_CONFIG,
|
|
48
|
+
"export const later = (): Promise<unknown> => import('@/platform/config/app-config.mjs');\n",
|
|
49
|
+
]),
|
|
50
|
+
failing('".js" in a test under "none"', NONE, [JOURNEY, "export { start } from '$test/e2e/support/start.js';\n"]),
|
|
51
|
+
failing('".js" in a script under "none"', NONE, [
|
|
52
|
+
SCRIPT,
|
|
53
|
+
"export { appConfig } from '@/platform/config/app-config.js';\n",
|
|
54
|
+
]),
|
|
55
|
+
{
|
|
56
|
+
ruleId: RULE,
|
|
57
|
+
name: 'a directory under "none": the compiler would complete it with its index',
|
|
58
|
+
expect: { file: LOAD_CONFIG },
|
|
59
|
+
files: project({
|
|
60
|
+
[APP_CONFIG]: SETTINGS,
|
|
61
|
+
[INDEX]: "export { appConfig } from '@/platform/config/app-config';\n",
|
|
62
|
+
[LOAD_CONFIG]: "export { appConfig } from '@/platform/config';\n",
|
|
63
|
+
}, NONE),
|
|
64
|
+
},
|
|
65
|
+
failing('no extension under "js"', JS, [LOAD_CONFIG, "export { appConfig } from '@/platform/config/app-config';\n"]),
|
|
66
|
+
failing('".ts" under "js"', JS, [LOAD_CONFIG, "export { appConfig } from '@/platform/config/app-config.ts';\n"]),
|
|
67
|
+
failing('no extension in a project whose config does not say', {}, [
|
|
68
|
+
JOURNEY,
|
|
69
|
+
"export { appConfig } from '@/platform/config/app-config';\n",
|
|
70
|
+
]),
|
|
71
|
+
];
|
|
72
|
+
/** One file that writes an import the config does not allow, in a project whose config is `overrides`. */
|
|
73
|
+
function failing(name, overrides, [file, content]) {
|
|
74
|
+
const files = project({ [APP_CONFIG]: SETTINGS, [file]: content }, overrides);
|
|
75
|
+
return { ruleId: RULE, name, expect: { file }, files };
|
|
76
|
+
}
|
|
77
|
+
//# sourceMappingURL=extension-fixtures.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"extension-fixtures.js","sourceRoot":"","sources":["../../../src/check/fixtures/extension-fixtures.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AACpD,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAErC,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AAEvC,MAAM,IAAI,GAAG,mBAAmB,CAAC;AACjC,MAAM,WAAW,GAAG,oCAAoC,CAAC;AACzD,MAAM,UAAU,GAAG,mCAAmC,CAA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AE,CAAC;AACzD,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fixtures.d.ts","sourceRoot":"","sources":["../../../src/check/fixtures/fixtures.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"fixtures.d.ts","sourceRoot":"","sources":["../../../src/check/fixtures/fixtures.ts"],"names":[],"mappings":"AA6BA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AAE5C;;;;GAIG;AACH,eAAO,MAAM,QAAQ,EAAE,SAAS,OAAO,EA8BtC,CAAC"}
|
|
@@ -4,12 +4,14 @@ import { AUTHZ_FIXTURES } from './authz-fixtures.js';
|
|
|
4
4
|
import { CLEAN_FIXTURES } from './clean-fixtures.js';
|
|
5
5
|
import { COMPOSITION_FIXTURES } from './composition-fixtures.js';
|
|
6
6
|
import { CONFIG_FIXTURES } from './config-fixtures.js';
|
|
7
|
+
import { CONSTRUCTOR_INJECTION_FIXTURES } from './constructor-injection-fixtures.js';
|
|
7
8
|
import { CONSUMER_FIXTURES } from './consumer-fixtures.js';
|
|
8
9
|
import { CONTEXT_FIXTURES } from './context-fixtures.js';
|
|
9
10
|
import { COVERAGE_FIXTURES } from './coverage-fixtures.js';
|
|
10
11
|
import { DECLARATIONS_FIXTURES } from './declarations-fixtures.js';
|
|
11
12
|
import { DOMAIN_EVENTS_FIXTURES } from './domain-events-fixtures.js';
|
|
12
13
|
import { EVENTS_FIXTURES } from './events-fixtures.js';
|
|
14
|
+
import { EXTENSION_FIXTURES } from './extension-fixtures.js';
|
|
13
15
|
import { EXTRACTABLE_FIXTURES } from './extractable-fixtures.js';
|
|
14
16
|
import { GOVERNANCE_FIXTURES } from './governance-fixtures.js';
|
|
15
17
|
import { IMPORTS_FIXTURES } from './imports-fixtures.js';
|
|
@@ -37,12 +39,14 @@ export const FIXTURES = [
|
|
|
37
39
|
...CLEAN_FIXTURES,
|
|
38
40
|
...COMPOSITION_FIXTURES,
|
|
39
41
|
...CONFIG_FIXTURES,
|
|
42
|
+
...CONSTRUCTOR_INJECTION_FIXTURES,
|
|
40
43
|
...CONSUMER_FIXTURES,
|
|
41
44
|
...CONTEXT_FIXTURES,
|
|
42
45
|
...COVERAGE_FIXTURES,
|
|
43
46
|
...DECLARATIONS_FIXTURES,
|
|
44
47
|
...DOMAIN_EVENTS_FIXTURES,
|
|
45
48
|
...EVENTS_FIXTURES,
|
|
49
|
+
...EXTENSION_FIXTURES,
|
|
46
50
|
...EXTRACTABLE_FIXTURES,
|
|
47
51
|
...GOVERNANCE_FIXTURES,
|
|
48
52
|
...IMPORTS_FIXTURES,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fixtures.js","sourceRoot":"","sources":["../../../src/check/fixtures/fixtures.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAAE,MAAM,8BAA8B,CAAC;AACvE,OAAO,EAAE,uBAAuB,EAAE,MAAM,8BAA8B,CAAC;AACvE,OAAO,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AACrD,OAAO,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AACrD,OAAO,EAAE,oBAAoB,EAAE,MAAM,2BAA2B,CAAC;AACjE,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AACvD,OAAO,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AACzD,OAAO,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAC3D,OAAO,EAAE,qBAAqB,EAAE,MAAM,4BAA4B,CAAC;AACnE,OAAO,EAAE,sBAAsB,EAAE,MAAM,6BAA6B,CAAC;AACrE,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AACvD,OAAO,EAAE,oBAAoB,EAAE,MAAM,2BAA2B,CAAC;AACjE,OAAO,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAC/D,O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E,eAAe,EAAE,MAAM,sBAAsB,CAAC;AACvD,OAAO,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AACrD,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AACvD,OAAO,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAC/D,OAAO,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAC3D,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AACnD,OAAO,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AACzD,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AAGnD;;;;GAIG;AACH,MAAM,CAAC,MAAM,QAAQ,GAAuB;IAC1C,GAAG,uBAAuB;IAC1B,GAAG,uBAAuB;IAC1B,GAAG,cAAc;IACjB,GAAG,cAAc;IACjB,GAAG,oBAAoB;IACvB,GAAG,eAAe;IAClB,GAAG,8BAA8B;IACjC,GAAG,iBAAiB;IACpB,GAAG,gBAAgB;IACnB,GAAG,iBAAiB;IACpB,GAAG,qBAAqB;IACxB,GAAG,sBAAsB;IACzB,GAAG,eAAe;IAClB,GAAG,kBAAkB;IACrB,GAAG,oBAAoB;IACvB,GAAG,mBAAmB;IACtB,GAAG,gBAAgB;IACnB,GAAG,iBAAiB;IACpB,GAAG,cAAc;IACjB,GAAG,eAAe;IAClB,GAAG,eAAe;IAClB,GAAG,eAAe;IAClB,GAAG,cAAc;IACjB,GAAG,eAAe;IAClB,GAAG,mBAAmB;IACtB,GAAG,iBAAiB;IACpB,GAAG,aAAa;IAChB,GAAG,gBAAgB;IACnB,GAAG,aAAa;CACjB,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { FixtureFiles } from './fixture-files.js';
|
|
2
|
+
type Assembly = 'barrel' | 'discovery';
|
|
3
|
+
/**
|
|
4
|
+
* A declared project that states dependencies in constructor signatures, holding the
|
|
5
|
+
* issue-invoice use case with the handler it is given. Its barrel is the one the generator
|
|
6
|
+
* derives from the role files alone: a fixture whose handler is injected something writes the
|
|
7
|
+
* generated file out, so that it does not prove the rule with its own code.
|
|
8
|
+
*/
|
|
9
|
+
export declare function signatureProject(body: string, overrides?: FixtureFiles, assembly?: Assembly): FixtureFiles;
|
|
10
|
+
export {};
|
|
11
|
+
//# sourceMappingURL=signature-project.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"signature-project.d.ts","sourceRoot":"","sources":["../../../src/check/fixtures/signature-project.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAIvD,KAAK,QAAQ,GAAG,QAAQ,GAAG,WAAW,CAAC;AAEvC;;;;;GAKG;AACH,wBAAgB,gBAAgB,CAC9B,IAAI,EAAE,MAAM,EACZ,SAAS,GAAE,YAAiB,EAC5B,QAAQ,GAAE,QAAmB,GAC5B,YAAY,CASd"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { CONFIG_FILE } from '../../config/index.js';
|
|
2
|
+
import { config } from './config.js';
|
|
3
|
+
import { DECLARED } from './declared.js';
|
|
4
|
+
import { declaredProject } from './declared-project.js';
|
|
5
|
+
import { handler } from './handler.js';
|
|
6
|
+
import { PATHS } from './paths.js';
|
|
7
|
+
/**
|
|
8
|
+
* A declared project that states dependencies in constructor signatures, holding the
|
|
9
|
+
* issue-invoice use case with the handler it is given. Its barrel is the one the generator
|
|
10
|
+
* derives from the role files alone: a fixture whose handler is injected something writes the
|
|
11
|
+
* generated file out, so that it does not prove the rule with its own code.
|
|
12
|
+
*/
|
|
13
|
+
export function signatureProject(body, overrides = {}, assembly = 'barrel') {
|
|
14
|
+
const stack = { style: 'declared', dependencies: 'signature', assembly };
|
|
15
|
+
const files = declaredProject({ [PATHS.REPOSITORY_PORT]: DECLARED.repositoryPort, [PATHS.COMMAND]: DECLARED.command, ...handler(body) }, { [CONFIG_FILE]: config({ stack }), ...overrides });
|
|
16
|
+
return assembly === 'barrel' ? files : withoutBarrels(files);
|
|
17
|
+
}
|
|
18
|
+
function withoutBarrels(files) {
|
|
19
|
+
return Object.fromEntries(Object.entries(files).filter(([file]) => !file.endsWith('.declarations.ts')));
|
|
20
|
+
}
|
|
21
|
+
//# sourceMappingURL=signature-project.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"signature-project.js","sourceRoot":"","sources":["../../../src/check/fixtures/signature-project.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AACpD,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AACzC,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAExD,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AAInC;;;;;GAKG;AACH,MAAM,UAAU,gBAAgB,CAC9B,IAAY,EACZ,SAAS,GAAiB,EAAE,EAC5B,QAAQ,GAAa,QAAQ;IAE7B,MAAM,KAAK,GAAG,EAAE,KAAK,EAAE,UAAU,EAAE,YAAY,EAAE,WAAW,EAAE,QAAQ,EAAE,CAAC;IAEzE,MAAM,KAAK,GAAG,eAAe,CAC3B,EAAE,CAAC,KAAK,CAAC,eAAe,CAAC,EAAE,QAAQ,CAAC,cAAc,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,EAAE,QAAQ,CAAC,OAAO,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC,EAAE,EACzG,EAAE,CAAC,WAAW,CAAC,EAAE,MAAM,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,GAAG,SAAS,EAAE,CACnD,CAAC;IAEF,OAAO,QAAQ,KAAK,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC;AAC/D,CAAC;AAED,SAAS,cAAc,CAAC,KAAmB;IACzC,OAAO,MAAM,CAAC,WAAW,CAAC,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC,EAAE,EAAE,CAAC,CAAC,IAAI,CAAC,QAAQ,CAAC,kBAAkB,CAAC,CAAC,CAAC,CAAC;AAC1G,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/** A handler whose constructor states its dependencies, and what the generated files of its context then hold. */
|
|
2
|
+
export declare const SIGNATURE: {
|
|
3
|
+
readonly handler: string;
|
|
4
|
+
readonly handlerOf: typeof handler;
|
|
5
|
+
readonly ports: string[];
|
|
6
|
+
readonly taken: string[];
|
|
7
|
+
readonly barrel: string;
|
|
8
|
+
readonly dependencies: string;
|
|
9
|
+
};
|
|
10
|
+
/** The issue-invoice handler, declared with `decorator`, importing `imports` and taking `parameters`. */
|
|
11
|
+
declare function handler(decorator: string, imports: readonly string[], parameters: readonly string[]): string;
|
|
12
|
+
export {};
|
|
13
|
+
//# sourceMappingURL=signature.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"signature.d.ts","sourceRoot":"","sources":["../../../src/check/fixtures/signature.ts"],"names":[],"mappings":"AAcA,kHAAkH;AAClH,eAAO,MAAM,SAAS;aACpB,OAAO;aACP,SAAS;aACT,KAAK;aACL,KAAK;aACL,MAAM;aAWN,YAAY;CAQJ,CAAC;AAEX,yGAAyG;AACzG,iBAAS,OAAO,CAAC,SAAS,EAAE,MAAM,EAAE,OAAO,EAAE,SAAS,MAAM,EAAE,EAAE,UAAU,EAAE,SAAS,MAAM,EAAE,GAAG,MAAM,CAarG"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { source } from './source.js';
|
|
2
|
+
const DECLARATIONS = "'@ddd-ts-kit/kernel/declarations'";
|
|
3
|
+
const COMMAND = "'@/contexts/billing/application/commands/issue-invoice/issue-invoice.command.js'";
|
|
4
|
+
const HANDLER = "'@/contexts/billing/application/commands/issue-invoice/issue-invoice.handler.js'";
|
|
5
|
+
const REPOSITORY = "'@/contexts/billing/domain/repositories/invoice.repository.js'";
|
|
6
|
+
const PORTS = [
|
|
7
|
+
"import type { Clock } from '@ddd-ts-kit/kernel';",
|
|
8
|
+
`import type { InvoiceRepository } from ${REPOSITORY};`,
|
|
9
|
+
];
|
|
10
|
+
const TAKEN = ['private readonly invoiceRepository: InvoiceRepository', 'private readonly clock: Clock'];
|
|
11
|
+
/** A handler whose constructor states its dependencies, and what the generated files of its context then hold. */
|
|
12
|
+
export const SIGNATURE = {
|
|
13
|
+
handler: handler('@CommandHandler(IssueInvoiceCommand)', PORTS, TAKEN),
|
|
14
|
+
handlerOf: handler,
|
|
15
|
+
ports: PORTS,
|
|
16
|
+
taken: TAKEN,
|
|
17
|
+
barrel: source(`import { injected } from ${DECLARATIONS};`, `import { IssueInvoiceHandler } from ${HANDLER};`, `import { InvoiceRepository } from ${REPOSITORY};`, "import { Clock } from '@ddd-ts-kit/kernel';", '', `export * from ${COMMAND};`, `export * from ${HANDLER};`, '', 'injected(IssueInvoiceHandler, [InvoiceRepository, Clock]);'),
|
|
18
|
+
dependencies: source(`import { injected } from ${DECLARATIONS};`, `import { IssueInvoiceHandler } from ${HANDLER};`, `import { InvoiceRepository } from ${REPOSITORY};`, "import { Clock } from '@ddd-ts-kit/kernel';", '', 'injected(IssueInvoiceHandler, [InvoiceRepository, Clock]);'),
|
|
19
|
+
};
|
|
20
|
+
/** The issue-invoice handler, declared with `decorator`, importing `imports` and taking `parameters`. */
|
|
21
|
+
function handler(decorator, imports, parameters) {
|
|
22
|
+
return source(...imports, `import { CommandHandler } from ${DECLARATIONS};`, `import { IssueInvoiceCommand } from ${COMMAND};`, '', decorator, 'export class IssueInvoiceHandler implements CommandHandler<IssueInvoiceCommand> {', ' constructor(', ...parameters.map((parameter) => ` ${parameter},`), ' ) {}', '}');
|
|
23
|
+
}
|
|
24
|
+
//# sourceMappingURL=signature.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"signature.js","sourceRoot":"","sources":["../../../src/check/fixtures/signature.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAErC,MAAM,YAAY,GAAG,mCAAmC,CAAC;AACzD,MAAM,OAAO,GAAG,kFAAkF,CAAC;AACnG,MAAM,OAAO,GAAG,kFAAkF,CAAC;AACnG,MAAM,UAAU,GAAG,gEAAgE,CAAC;AAEpF,MAAM,KAAK,GAAG;IACZ,kDAAkD;IAClD,0CAA0C,UAAU,GAAG;CACxD,CAAC;AAEF,MAAM,KAAK,GAAG,CAAC,uDAAuD,EAAE,+BAA+B,CAAC,CAAC;AAEzG,kHAAkH;AAClH,MAAM,CAAC,MAAM,SAAS,GAAG;IACvB,OAAO,EAAE,OAAO,CAAC,sCAAsC,EAAE,KAAK,EAAE,KAAK,CAAC;IACtE,SAAS,EAAE,OAAO;IAClB,KAAK,EAAE,KAAK;IACZ,KAAK,EAAE,KAAK;IACZ,MAAM,EAAE,MAAM,CACZ,4BAA4B,YAAY,GAAG,EAC3C,uCAAuC,OAAO,GAAG,EACjD,qCAAqC,UAAU,GAAG,EAClD,6CAA6C,EAC7C,EAAE,EACF,iBAAiB,OAAO,GAAG,EAC3B,iBAAiB,OAAO,GAAG,EAC3B,EAAE,EACF,4DAA4D,CAC7D;IACD,YAAY,EAAE,MAAM,CAClB,4BAA4B,YAAY,GAAG,EAC3C,uCAAuC,OAAO,GAAG,EACjD,qCAAqC,UAAU,GAAG,EAClD,6CAA6C,EAC7C,EAAE,EACF,4DAA4D,CAC7D;CACO,CAAC;AAEX,yGAAyG;AACzG,SAAS,OAAO,CAAC,SAAiB,EAAE,OAA0B,EAAE,UAA6B;IAC3F,OAAO,MAAM,CACX,GAAG,OAAO,EACV,kCAAkC,YAAY,GAAG,EACjD,uCAAuC,OAAO,GAAG,EACjD,EAAE,EACF,SAAS,EACT,mFAAmF,EACnF,gBAAgB,EAChB,GAAG,UAAU,CAAC,GAAG,CAAC,CAAC,SAAS,EAAE,EAAE,CAAC,OAAO,SAAS,GAAG,CAAC,EACrD,QAAQ,EACR,GAAG,CACJ,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { Project } from '../model/project.js';
|
|
2
|
+
import type { SourceFile } from '../model/source-file.js';
|
|
3
|
+
/** The TypeScript sources of the tests and of the scripts, which live next to the source root. */
|
|
4
|
+
export declare function besideTheSources(project: Pick<Project, 'root' | 'config'>): SourceFile[];
|
|
5
|
+
//# sourceMappingURL=beside-the-sources.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"beside-the-sources.d.ts","sourceRoot":"","sources":["../../../src/check/project/beside-the-sources.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AAQ1D,kGAAkG;AAClG,wBAAgB,gBAAgB,CAAC,OAAO,EAAE,IAAI,CAAC,OAAO,EAAE,MAAM,GAAG,QAAQ,CAAC,GAAG,UAAU,EAAE,CAYxF"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import fs from 'node:fs';
|
|
2
|
+
import path from 'node:path';
|
|
3
|
+
import { FIXED_ALIAS_ROOTS } from '../../alias/index.js';
|
|
4
|
+
import { isSource } from './is-source.js';
|
|
5
|
+
import { loadSourceFile } from './load-source-file.js';
|
|
6
|
+
import { walkDirectory } from './walk-directory.js';
|
|
7
|
+
/** The trees `check` does not walk for the other rules: their files are read for their imports only. */
|
|
8
|
+
const BESIDE_THE_SOURCES = [FIXED_ALIAS_ROOTS.test.directory, FIXED_ALIAS_ROOTS.scripts.directory];
|
|
9
|
+
/** The TypeScript sources of the tests and of the scripts, which live next to the source root. */
|
|
10
|
+
export function besideTheSources(project) {
|
|
11
|
+
const files = [];
|
|
12
|
+
for (const directory of BESIDE_THE_SOURCES) {
|
|
13
|
+
walkDirectory(project.root, directory, (file, isDirectory) => {
|
|
14
|
+
if (!isDirectory && isSource(file)) {
|
|
15
|
+
files.push(loadSourceFile(project.config, file, fs.readFileSync(path.join(project.root, file), 'utf8')));
|
|
16
|
+
}
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
return files;
|
|
20
|
+
}
|
|
21
|
+
//# sourceMappingURL=beside-the-sources.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"beside-the-sources.js","sourceRoot":"","sources":["../../../src/check/project/beside-the-sources.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAGzD,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEpD,wGAAwG;AACxG,MAAM,kBAAkB,GAAG,CAAC,iBAAiB,CAAC,IAAI,CAAC,SAAS,EAAE,iBAAiB,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC;AAEnG,kGAAkG;AAClG,MAAM,UAAU,gBAAgB,CAAC,OAAyC;IACxE,MAAM,KAAK,GAAiB,EAAE,CAAC;IAE/B,KAAK,MAAM,SAAS,IAAI,kBAAkB,EAAE,CAAC;QAC3C,aAAa,CAAC,OAAO,CAAC,IAAI,EAAE,SAAS,EAAE,CAAC,IAAI,EAAE,WAAW,EAAE,EAAE;YAC3D,IAAI,CAAC,WAAW,IAAI,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC;gBACnC,KAAK,CAAC,IAAI,CAAC,cAAc,CAAC,OAAO,CAAC,MAAM,EAAE,IAAI,EAAE,EAAE,CAAC,YAAY,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,IAAI,EAAE,IAAI,CAAC,EAAE,MAAM,CAAC,CAAC,CAAC,CAAC;YAC3G,CAAC;QACH,CAAC,CAAC,CAAC;IACL,CAAC;IAED,OAAO,KAAK,CAAC;AACf,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"resolve-import.d.ts","sourceRoot":"","sources":["../../../src/check/project/resolve-import.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,uBAAuB,CAAC;AACpD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;
|
|
1
|
+
{"version":3,"file":"resolve-import.d.ts","sourceRoot":"","sources":["../../../src/check/project/resolve-import.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,uBAAuB,CAAC;AACpD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AAQ9D,iGAAiG;AACjG,wBAAgB,aAAa,CAAC,MAAM,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,GAAG,YAAY,CAoB/F"}
|
|
@@ -3,6 +3,8 @@ import path from 'node:path';
|
|
|
3
3
|
import { aliasRoots } from '../../alias/index.js';
|
|
4
4
|
import { locate } from './locate.js';
|
|
5
5
|
const SOURCE = /\.(?:ts|mts|cts)$/;
|
|
6
|
+
/** A file that is not a module of the project, named with its own extension. */
|
|
7
|
+
const ASSET = /\.(?:json|node|wasm|[jt]sx)$/;
|
|
6
8
|
const BUILTINS = new Set(builtinModules);
|
|
7
9
|
/** Classifies by path alone: the imported file does not have to exist for a rule to judge it. */
|
|
8
10
|
export function resolveImport(config, fromFile, specifier) {
|
|
@@ -23,7 +25,8 @@ export function resolveImport(config, fromFile, specifier) {
|
|
|
23
25
|
}
|
|
24
26
|
function asFile(config, target) {
|
|
25
27
|
const clean = path.posix.normalize(target).replace(/\.(?:js|mjs|cjs)$/, '.ts');
|
|
26
|
-
|
|
28
|
+
// Written without its extension, a module is named by what remains, dots included: `invoice.aggregate` is `invoice.aggregate.ts`.
|
|
29
|
+
const withExtension = SOURCE.test(clean) || ASSET.test(clean) ? clean : `${clean}.ts`;
|
|
27
30
|
return { kind: 'file', path: withExtension, location: locate(config, withExtension) };
|
|
28
31
|
}
|
|
29
32
|
function packageName(specifier) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"resolve-import.js","sourceRoot":"","sources":["../../../src/check/project/resolve-import.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAC7C,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAGlD,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAErC,MAAM,MAAM,GAAG,mBAAmB,CAAC;AACnC,MAAM,QAAQ,GAAG,IAAI,GAAG,CAAC,cAAc,CAAC,CAAC;AAEzC,iGAAiG;AACjG,MAAM,UAAU,aAAa,CAAC,MAAc,EAAE,QAAgB,EAAE,SAAiB;IAC/E,IAAI,SAAS,CAAC,UAAU,CAAC,GAAG,CAAC,EAAE,CAAC;QAC9B,OAAO,MAAM,CAAC,MAAM,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,QAAQ,CAAC,EAAE,SAAS,CAAC,CAAC,CAAC;IAClF,CAAC;IAED,MAAM,IAAI,GAAG,UAAU,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,CAAC,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC,MAAM,KAAK,EAAE,IAAI,SAAS,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC,CAAC;IAEpG,IAAI,IAAI,KAAK,SAAS,EAAE,CAAC;QACvB,OAAO,MAAM,CAAC,MAAM,EAAE,IAAI,CAAC,KAA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AAC,CAAC,OAAO,CAAC,mBAAmB,EAAE,KAAK,CAAC,CAAC;IAC/E,kIAAkI;IAClI,MAAM,aAAa,GAAG,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,GAAG,KAAK,KAAK,CAAC;IAEtF,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,aAAa,EAAE,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,aAAa,CAAC,EAAE,CAAC;AACxF,CAAC;AAED,SAAS,WAAW,CAAC,SAAiB;IACpC,MAAM,CAAC,KAAK,GAAG,EAAE,EAAE,MAAM,CAAC,GAAG,SAAS,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IAElD,OAAO,KAAK,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,MAAM,KAAK,SAAS,CAAC,CAAC,CAAC,GAAG,KAAK,IAAI,MAAM,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC;AACtF,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"clean-one-export-per-file.d.ts","sourceRoot":"","sources":["../../../src/check/rules/clean-one-export-per-file.ts"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAgB7C,eAAO,MAAM,qBAAqB,EAAE,
|
|
1
|
+
{"version":3,"file":"clean-one-export-per-file.d.ts","sourceRoot":"","sources":["../../../src/check/rules/clean-one-export-per-file.ts"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAgB7C,eAAO,MAAM,qBAAqB,EAAE,IAkBnC,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import path from 'node:path';
|
|
2
|
-
import { barrelFile } from '../../declared/index.js';
|
|
2
|
+
import { barrelFile, dependenciesFile } from '../../declared/index.js';
|
|
3
3
|
import { judgeExports } from '../exports/judge-exports.js';
|
|
4
4
|
import { kebabCaseOf } from '../exports/kebab-case-of.js';
|
|
5
5
|
import { matchesGlob } from '../exports/matches-glob.js';
|
|
@@ -19,6 +19,9 @@ export const cleanOneExportPerFile = {
|
|
|
19
19
|
if (!isJudged(file, project)) {
|
|
20
20
|
return [];
|
|
21
21
|
}
|
|
22
|
+
if (isGenerated(file)) {
|
|
23
|
+
return [];
|
|
24
|
+
}
|
|
22
25
|
return isEntry(file) ? declaredInEntry(file) : judged(file, project);
|
|
23
26
|
});
|
|
24
27
|
},
|
|
@@ -32,15 +35,18 @@ function isJudged(file, project) {
|
|
|
32
35
|
}
|
|
33
36
|
return file.path.startsWith(`${root}/`) || segments.slice(0, -1).includes(path.posix.basename(root));
|
|
34
37
|
}
|
|
35
|
-
/**
|
|
36
|
-
function
|
|
38
|
+
/** The generated files of a declared context: `declarations/barrel-current` holds every line of them. */
|
|
39
|
+
function isGenerated(file) {
|
|
37
40
|
const name = path.posix.basename(file.path);
|
|
38
41
|
const { location } = file;
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
42
|
+
if (location.area !== 'context' || location.layer !== 'root' || location.inside.length > 0) {
|
|
43
|
+
return false;
|
|
44
|
+
}
|
|
45
|
+
return name === barrelFile(location.context) || name === dependenciesFile(location.context);
|
|
46
|
+
}
|
|
47
|
+
/** `index.ts` at any depth. */
|
|
48
|
+
function isEntry(file) {
|
|
49
|
+
return /^index\.[cm]?ts$/.test(path.posix.basename(file.path));
|
|
44
50
|
}
|
|
45
51
|
/** Everything of an entry file that is not a re-export, an import without binding or the empty `export {};`. */
|
|
46
52
|
function declaredInEntry(file) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"clean-one-export-per-file.js","sourceRoot":"","sources":["../../../src/check/rules/clean-one-export-per-file.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B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AAC,CAAC,EAAE,IAAI,EAAE,EAAE,EAAE,CAAC,IAAI,KAAK,SAAS,IAAI,UAAU,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC,EAAE,CAAC;QAClG,OAAO,EAAE,CAAC;IACZ,CAAC;IAED,MAAM,QAAQ,GAAG,WAAW,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;IAEzC,OAAO;QACL;YACE,IAAI,EAAE,KAAK,CAAC,IAAI;YAChB,OAAO,EAAE,IAAI,IAAI,yCAAyC,KAAK,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,EAAE,EAAE,EAAE,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI;YACtG,GAAG,EAAE,mBAAmB,QAAQ,QAAQ,QAAQ,uKAAuK;SACxN;KACF,CAAC;AACJ,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config-valid.d.ts","sourceRoot":"","sources":["../../../src/check/rules/config-valid.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAG7C,eAAO,MAAM,WAAW,EAAE,
|
|
1
|
+
{"version":3,"file":"config-valid.d.ts","sourceRoot":"","sources":["../../../src/check/rules/config-valid.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAG7C,eAAO,MAAM,WAAW,EAAE,IAsBzB,CAAC"}
|
|
@@ -3,7 +3,7 @@ import { ConfigInspection } from '../configuration/config-inspection.js';
|
|
|
3
3
|
import { reporter } from '../support/reporter.js';
|
|
4
4
|
export const configValid = {
|
|
5
5
|
id: 'config/valid',
|
|
6
|
-
description: 'ddd-ts-kit.config.json is consistent: known contexts, classifications, relationships, rule ids and
|
|
6
|
+
description: 'ddd-ts-kit.config.json is consistent: known contexts, classifications, relationships, rule ids, guard mode and import extension, the same contexts as on disk, a function limit within the ceiling, complete onePerFile.allow entries, positive commit limits and coverage thresholds that are percentages.',
|
|
7
7
|
scope: 'project',
|
|
8
8
|
run(project) {
|
|
9
9
|
const inspection = new ConfigInspection(project, reporter(project, this.id));
|
|
@@ -12,6 +12,7 @@ export const configValid = {
|
|
|
12
12
|
...inspection.undeclaredDirectories(),
|
|
13
13
|
...inspection.ruleSettings(KNOWN_RULE_IDS),
|
|
14
14
|
...inspection.guardMode(),
|
|
15
|
+
...inspection.importExtension(),
|
|
15
16
|
...inspection.functionLinesLimit(),
|
|
16
17
|
...inspection.onePerFileAllowances(),
|
|
17
18
|
...inspection.commitLimits(),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config-valid.js","sourceRoot":"","sources":["../../../src/check/rules/config-valid.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,gCAAgC,CAAC;AAChE,OAAO,EAAE,gBAAgB,EAAE,MAAM,uCAAuC,CAAC;AAEzE,OAAO,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAElD,MAAM,CAAC,MAAM,WAAW,GAAS;IAC/B,EAAE,EAAE,cAAc;IAClB,WAAW,EACT,
|
|
1
|
+
{"version":3,"file":"config-valid.js","sourceRoot":"","sources":["../../../src/check/rules/config-valid.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,gCAAgC,CAAC;AAChE,OAAO,EAAE,gBAAgB,EAAE,MAAM,uCAAuC,CAAC;AAEzE,OAAO,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAElD,MAAM,CAAC,MAAM,WAAW,GAAS;IAC/B,EAAE,EAAE,cAAc;IAClB,WAAW,EACT,6SAA6S;IAC/S,KAAK,EAAE,SAAS;IAChB,GAAG,CAAC,OAAO;QACT,MAAM,UAAU,GAAG,IAAI,gBAAgB,CAAC,OAAO,EAAE,QAAQ,CAAC,OAAO,EAAE,IAAI,CAAC,EAAE,CAAC,CAAC,CAAC;QAE7E,OAAO;YACL,GAAG,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,IAAI,EAAE,OAAO,CAAC,EAAE,EAAE,CACrE,UAAU,CAAC,eAAe,CAAC,IAAI,EAAE,OAAO,CAAC,CAC1C;YACD,GAAG,UAAU,CAAC,qBAAqB,EAAE;YACrC,GAAG,UAAU,CAAC,YAAY,CAAC,cAAc,CAAC;YAC1C,GAAG,UAAU,CAAC,SAAS,EAAE;YACzB,GAAG,UAAU,CAAC,eAAe,EAAE;YAC/B,GAAG,UAAU,CAAC,kBAAkB,EAAE;YAClC,GAAG,UAAU,CAAC,oBAAoB,EAAE;YACpC,GAAG,UAAU,CAAC,YAAY,EAAE;YAC5B,GAAG,UAAU,CAAC,kBAAkB,EAAE;SACnC,CAAC;IACJ,CAAC;CACF,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"declarations-barrel-current.d.ts","sourceRoot":"","sources":["../../../src/check/rules/declarations-barrel-current.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"declarations-barrel-current.d.ts","sourceRoot":"","sources":["../../../src/check/rules/declarations-barrel-current.ts"],"names":[],"mappings":"AAYA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAa7C,eAAO,MAAM,yBAAyB,EAAE,IAiBvC,CAAC"}
|
|
@@ -1,44 +1,59 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { barrelFile, renderBarrel } from '../../declared/index.js';
|
|
1
|
+
import { specifierOf } from '../../alias/index.js';
|
|
2
|
+
import { barrelFile, contextInjections, dependenciesFile, generatedDrift, renderBarrel, renderDependenciesFile, renderInjections, } from '../../declared/index.js';
|
|
3
|
+
import { sourceAt } from '../project/source-at.js';
|
|
3
4
|
import { isDeclaredStyle } from '../support/is-declared-style.js';
|
|
4
5
|
import { reporter } from '../support/reporter.js';
|
|
5
|
-
const REGENERATE = 'Run `ddd-ts-kit
|
|
6
|
-
const EXPORT = /^export \* from '(.+)';$/;
|
|
6
|
+
const REGENERATE = 'Run `ddd-ts-kit docs`, or `ddd-ts-kit generate` again, which rewrite it: the file is derived from the role files of the context and from their constructor signatures, and never edited by hand.';
|
|
7
7
|
export const declarationsBarrelCurrent = {
|
|
8
8
|
id: 'declarations/barrel-current',
|
|
9
|
-
description: 'In the declared style
|
|
9
|
+
description: 'In the declared style, the generated file of a context is what its tree says: <context>.declarations.ts lists exactly its role files and registers the dependency list read from each constructor; under discovery <context>.dependencies.ts registers the lists alone.',
|
|
10
10
|
scope: 'project',
|
|
11
11
|
run(project) {
|
|
12
12
|
if (!isDeclaredStyle(project)) {
|
|
13
13
|
return [];
|
|
14
14
|
}
|
|
15
15
|
const report = reporter(project, this.id);
|
|
16
|
-
const { contextsDir, contexts } = project.config;
|
|
17
16
|
return project.contextsOnDisk
|
|
18
|
-
.filter((context) => contexts[context] !== undefined)
|
|
19
|
-
.flatMap((context) =>
|
|
20
|
-
|
|
21
|
-
const flaw = judge(project, context, file);
|
|
22
|
-
return flaw === undefined ? [] : [report({ file, line: 1 }, flaw.message, flaw.fix)];
|
|
23
|
-
});
|
|
17
|
+
.filter((context) => project.config.contexts[context] !== undefined)
|
|
18
|
+
.flatMap((context) => judge(project, context))
|
|
19
|
+
.flatMap(({ file, flaw }) => (flaw === undefined ? [] : [report({ file, line: 1 }, flaw.message, flaw.fix)]));
|
|
24
20
|
},
|
|
25
21
|
};
|
|
26
|
-
function judge(project, context
|
|
27
|
-
const
|
|
22
|
+
function judge(project, context) {
|
|
23
|
+
const directory = `${project.config.contextsDir}/${context}`;
|
|
24
|
+
const barrel = `${directory}/${barrelFile(context)}`;
|
|
25
|
+
const entries = entriesOf(project, context);
|
|
26
|
+
const injections = contextInjections((file) => sourceAt(project, file), directory, entries);
|
|
27
|
+
const injected = renderInjections(injections, (file) => specifierOf(project.config, file));
|
|
28
28
|
if (project.config.stack.assembly === 'discovery') {
|
|
29
|
-
|
|
29
|
+
const lists = { name: 'dependency lists', expected: renderDependenciesFile(injected), optional: true };
|
|
30
|
+
return [
|
|
31
|
+
{ file: barrel, flaw: writtenIn(project, barrel) === undefined ? undefined : leftBehind(context) },
|
|
32
|
+
{ file: `${directory}/${dependenciesFile(context)}`, flaw: stale(project, context, lists) },
|
|
33
|
+
];
|
|
30
34
|
}
|
|
31
|
-
const expected = renderBarrel(
|
|
32
|
-
|
|
35
|
+
const expected = renderBarrel(entries, (entry) => specifierOf(project.config, `${directory}/${entry}`), injected);
|
|
36
|
+
return [{ file: barrel, flaw: stale(project, context, { name: 'barrel', expected, optional: false }) }];
|
|
37
|
+
}
|
|
38
|
+
function stale(project, context, { name, expected, optional }) {
|
|
39
|
+
const file = name === 'barrel' ? barrelFile(context) : dependenciesFile(context);
|
|
40
|
+
const written = writtenIn(project, `${project.config.contextsDir}/${context}/${file}`);
|
|
41
|
+
if (written === expected || (written === undefined && optional && expected === 'export {};\n')) {
|
|
33
42
|
return undefined;
|
|
34
43
|
}
|
|
35
44
|
if (written === undefined) {
|
|
36
45
|
return {
|
|
37
|
-
message: `The
|
|
46
|
+
message: `The ${name} of "${context}" ${name === 'barrel' ? 'is' : 'are'} missing: the composition root has nothing to ${name === 'barrel' ? 'assemble the context from' : 'inject its constructors from'}.`,
|
|
38
47
|
fix: REGENERATE,
|
|
39
48
|
};
|
|
40
49
|
}
|
|
41
|
-
return {
|
|
50
|
+
return {
|
|
51
|
+
message: `The ${name} of "${context}" ${name === 'barrel' ? 'is' : 'are'} stale: ${generatedDrift(written, expected)}.`,
|
|
52
|
+
fix: REGENERATE,
|
|
53
|
+
};
|
|
54
|
+
}
|
|
55
|
+
function writtenIn(project, file) {
|
|
56
|
+
return project.files.find((candidate) => candidate.path === file)?.text.replaceAll('\r\n', '\n');
|
|
42
57
|
}
|
|
43
58
|
function leftBehind(context) {
|
|
44
59
|
return {
|
|
@@ -53,17 +68,4 @@ function entriesOf(project, context) {
|
|
|
53
68
|
.filter((entry) => entry.startsWith(prefix) && !entry.endsWith('/'))
|
|
54
69
|
.map((entry) => entry.slice(prefix.length));
|
|
55
70
|
}
|
|
56
|
-
/** The first thing that tells the written barrel from the expected one, in words. */
|
|
57
|
-
function difference(written, expected) {
|
|
58
|
-
const exportsOf = (barrel) => barrel.split('\n').flatMap((line) => EXPORT.exec(line)?.[1] ?? []);
|
|
59
|
-
const missing = exportsOf(expected).find((specifier) => !exportsOf(written).includes(specifier));
|
|
60
|
-
if (missing !== undefined) {
|
|
61
|
-
return `it does not export ${missing}, so the class declared there is registered nowhere`;
|
|
62
|
-
}
|
|
63
|
-
const extra = exportsOf(written).find((specifier) => !exportsOf(expected).includes(specifier));
|
|
64
|
-
if (extra !== undefined) {
|
|
65
|
-
return `it exports ${extra}, which is not a role file of the context`;
|
|
66
|
-
}
|
|
67
|
-
return 'it holds something else than one `export * from` per role file, sorted by path';
|
|
68
|
-
}
|
|
69
71
|
//# sourceMappingURL=declarations-barrel-current.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"declarations-barrel-current.js","sourceRoot":"","sources":["../../../src/check/rules/declarations-barrel-current.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"declarations-barrel-current.js","sourceRoot":"","sources":["../../../src/check/rules/declarations-barrel-current.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AACnD,OAAO,EACL,UAAU,EACV,iBAAiB,EACjB,gBAAgB,EAChB,cAAc,EACd,YAAY,EACZ,sBAAsB,EACtB,gBAAgB,GACjB,MAAM,yBAAyB,CAAC;AAIjC,OAAO,EAAE,QAAQ,EAAE,MAAM,yBAAyB,CAAC;AACnD,OAAO,EAAE,eAAe,EAAE,MAAM,iCAAiC,CAAC;AAClE,OAAO,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAElD,MAAM,UAAU,GACd,kMAAkM,CAAC;AAOrM,MAAM,CAAC,MAAM,yBAAyB,GAAS;IAC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AAO,0BAA0B,OAAO,6FAA6F;KACrK,CAAC;AACJ,CAAC;AAED,8CAA8C;AAC9C,SAAS,SAAS,CAAC,OAAgB,EAAE,OAAe;IAClD,MAAM,MAAM,GAAG,GAAG,OAAO,CAAC,MAAM,CAAC,WAAW,IAAI,OAAO,GAAG,CAAC;IAE3D,OAAO,OAAO,CAAC,cAAc;SAC1B,MAAM,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,UAAU,CAAC,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC;SACnE,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,KAAK,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC;AAChD,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"declarations-constructor-injection.d.ts","sourceRoot":"","sources":["../../../src/check/rules/declarations-constructor-injection.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAO7C,eAAO,MAAM,gCAAgC,EAAE,IAwB9C,CAAC"}
|