@orkestrel/scaffold 0.0.71 → 0.0.73
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/host/CLAUDE.md +3 -3
- package/dist/host/agents/orchestration.md +66 -32
- package/dist/host/agents/skills/enterprise-bootstrap/references/bootstrap-reference.md +36 -6
- package/dist/host/agents/skills/enterprise-bootstrap/references/color-modes.md +3 -2
- package/dist/host/agents/skills/enterprise-bootstrap/references/components.md +1 -1
- package/dist/host/agents/skills/orkestrel-build-application/SKILL.md +18 -1
- package/dist/host/agents/skills/orkestrel-debrief/SKILL.md +1 -1
- package/dist/host/agents/skills/orkestrel-debrief/references/instruction-audit.md +2 -4
- package/dist/host/agents/skills/orkestrel-falsify/SKILL.md +12 -9
- package/dist/host/agents/skills/orkestrel-falsify/references/brief.md +16 -8
- package/dist/host/agents/skills/orkestrel-falsify/references/reconcile.md +2 -2
- package/dist/host/agents/skills/orkestrel-harden-package/SKILL.md +1 -1
- package/dist/host/agents/skills/orkestrel-polish-surface/SKILL.md +2 -1
- package/dist/host/agents/skills/orkestrel-prove-journey/SKILL.md +19 -8
- package/dist/host/agents/skills/orkestrel-prove-journey/references/layer.md +16 -15
- package/dist/host/agents/skills/orkestrel-prove-journey/references/statechart.md +5 -2
- package/dist/host/agents/skills/orkestrel-prove-journey/references/styles.md +5 -1
- package/dist/host/agents/templates/brief.md +4 -3
- package/dist/host/agents/transports/claude.md +13 -6
- package/dist/host/agents/transports/codex.md +2 -2
- package/dist/host/agents/transports/cursor.md +85 -0
- package/dist/host/claude/agents/application.md +5 -6
- package/dist/host/claude/agents/builder.md +3 -13
- package/dist/host/claude/agents/checker.md +9 -2
- package/dist/host/claude/agents/distiller.md +37 -0
- package/dist/host/claude/agents/grok.md +9 -56
- package/dist/host/claude/agents/{implementer.md → opus.md} +8 -9
- package/dist/host/claude/agents/orkestrel.md +53 -46
- package/dist/host/claude/agents/planner.md +12 -5
- package/dist/host/claude/agents/researcher.md +7 -0
- package/dist/host/claude/agents/reviewer.md +14 -7
- package/dist/host/claude/agents/scout.md +8 -1
- package/dist/host/claude/agents/sol.md +5 -5
- package/dist/host/claude/rules/documentation.md +1 -0
- package/dist/host/claude/rules/writing.md +27 -24
- package/dist/host/claude/skills/orkestrel-build-application/SKILL.md +1 -1
- package/dist/host/codex/agents/analyst.toml +10 -4
- package/dist/host/codex/agents/application.toml +5 -6
- package/dist/host/codex/agents/builder.toml +5 -5
- package/dist/host/codex/agents/checker.toml +4 -0
- package/dist/host/codex/agents/distiller.toml +28 -0
- package/dist/host/codex/agents/grok.toml +27 -19
- package/dist/host/codex/agents/opus.toml +5 -4
- package/dist/host/codex/agents/orkestrel.toml +5 -0
- package/dist/host/codex/agents/planner.toml +10 -0
- package/dist/host/codex/agents/researcher.toml +4 -0
- package/dist/host/codex/agents/reviewer.toml +12 -2
- package/dist/host/codex/agents/scout.toml +5 -2
- package/dist/host/codex/agents/{implementer.toml → sol.toml} +5 -6
- package/dist/host/codex/agents/verifier.toml +3 -0
- package/dist/host/codex/config.toml +2 -2
- package/dist/host/configs/policy.ts +5 -2
- package/dist/host/dotfiles/gitignore +3 -0
- package/dist/host/guides/test.md +77 -55
- package/dist/host/manifest.json +80 -72
- package/dist/host/tests/config.test.ts +113 -57
- package/dist/src/core/index.cjs +448 -349
- package/dist/src/core/index.cjs.map +1 -1
- package/dist/src/core/index.d.cts +22 -21
- package/dist/src/core/index.d.ts +22 -21
- package/dist/src/core/index.js +448 -349
- package/dist/src/core/index.js.map +1 -1
- package/package.json +4 -4
package/dist/src/core/index.cjs
CHANGED
|
@@ -4,7 +4,7 @@ let _orkestrel_template = require("@orkestrel/template");
|
|
|
4
4
|
let _orkestrel_emitter = require("@orkestrel/emitter");
|
|
5
5
|
var package_default = {
|
|
6
6
|
name: "@orkestrel/scaffold",
|
|
7
|
-
version: "0.0.
|
|
7
|
+
version: "0.0.73",
|
|
8
8
|
description: "Scaffold workspaces with commands: new, audit, repair, catalog, and overwrite.",
|
|
9
9
|
keywords: [
|
|
10
10
|
"audit",
|
|
@@ -99,10 +99,10 @@ var package_default = {
|
|
|
99
99
|
},
|
|
100
100
|
devDependencies: {
|
|
101
101
|
"@microsoft/api-extractor": "^7.59.1",
|
|
102
|
-
"@orkestrel/guide": "^0.0.
|
|
102
|
+
"@orkestrel/guide": "^0.0.20",
|
|
103
103
|
"@orkestrel/html": "^0.0.10",
|
|
104
|
-
"@orkestrel/probe": "^0.0.
|
|
105
|
-
"@orkestrel/test": "^0.0.
|
|
104
|
+
"@orkestrel/probe": "^0.0.16",
|
|
105
|
+
"@orkestrel/test": "^0.0.16",
|
|
106
106
|
"@types/node": "^26.5.1",
|
|
107
107
|
"@vitest/browser-playwright": "^4.1.11",
|
|
108
108
|
"oxfmt": "^0.68.0",
|
|
@@ -671,7 +671,8 @@ var CONFIG_TEMPLATES = Object.freeze({
|
|
|
671
671
|
"exclude": ["node_modules", "dist", "tmp"]
|
|
672
672
|
}
|
|
673
673
|
`,
|
|
674
|
-
vite: `import type {
|
|
674
|
+
vite: `import type { PluginOption, UserConfig } from 'vite'
|
|
675
|
+
import { mergeConfig } from 'vite'
|
|
675
676
|
{{imports}}import { defineConfig } from 'vitest/config'
|
|
676
677
|
import manifest from './package.json' with { type: 'json' }
|
|
677
678
|
import tsconfig from './tsconfig.json' with { type: 'json' }
|
|
@@ -701,6 +702,68 @@ const resolve = {
|
|
|
701
702
|
}, {}),
|
|
702
703
|
}
|
|
703
704
|
|
|
705
|
+
// Merges a caller's override onto the configuration a factory declares, so a
|
|
706
|
+
// package's own configuration reaches the factory through its parameter instead of
|
|
707
|
+
// wrapping the call from outside.
|
|
708
|
+
//
|
|
709
|
+
// Vitest calls every registered project factory with its own invocation record —
|
|
710
|
+
// \`command\`, \`mode\`, \`isSsrBuild\`, \`isPreview\` — so a factory that also takes an
|
|
711
|
+
// override receives that record in the same position. A \`UserConfig\` declares \`mode\`
|
|
712
|
+
// but not \`command\`, and the invocation record always carries both, so a value
|
|
713
|
+
// carrying the pair is that record rather than an override. The merge returns the
|
|
714
|
+
// base unchanged and reports nothing. The \`tests/config.test.ts\` file drives every
|
|
715
|
+
// registered factory through it.
|
|
716
|
+
//
|
|
717
|
+
// \`mergeConfig\` concatenates arrays, so an override carrying \`plugins\` would otherwise
|
|
718
|
+
// add a second copy of a plugin the base already declares. Only named top-level
|
|
719
|
+
// objects replace a base plugin of the same name, in the base's position, and one
|
|
720
|
+
// override entry is taken at most once. An entry no base position took appends in its
|
|
721
|
+
// written order; the caller's own entries never merge with each other. Nested arrays,
|
|
722
|
+
// promises, falsy entries, and anonymous objects pass through unchanged. An override
|
|
723
|
+
// cannot remove a base plugin. Every key other than \`plugins\` merges as \`mergeConfig\`
|
|
724
|
+
// merges it, so an override's arrays elsewhere concatenate with the base's rather than
|
|
725
|
+
// replacing them.
|
|
726
|
+
export function mergeOverride(base: UserConfig, override?: UserConfig): UserConfig {
|
|
727
|
+
if (override === undefined || ('command' in override && 'mode' in override)) return base
|
|
728
|
+
const merged: UserConfig = mergeConfig(base, override)
|
|
729
|
+
if (merged.plugins === undefined) return merged
|
|
730
|
+
const candidates = override.plugins ?? []
|
|
731
|
+
const taken = new Set<number>()
|
|
732
|
+
const selected: PluginOption[] = []
|
|
733
|
+
for (const plugin of base.plugins ?? []) {
|
|
734
|
+
if (!isNamedPlugin(plugin)) {
|
|
735
|
+
selected.push(plugin)
|
|
736
|
+
continue
|
|
737
|
+
}
|
|
738
|
+
const index = candidates.findIndex(
|
|
739
|
+
(candidate, position) =>
|
|
740
|
+
!taken.has(position) && isNamedPlugin(candidate) && candidate.name === plugin.name,
|
|
741
|
+
)
|
|
742
|
+
const replacement = candidates[index]
|
|
743
|
+
if (replacement === undefined) {
|
|
744
|
+
selected.push(plugin)
|
|
745
|
+
} else {
|
|
746
|
+
selected.push(replacement)
|
|
747
|
+
taken.add(index)
|
|
748
|
+
}
|
|
749
|
+
}
|
|
750
|
+
for (const [index, plugin] of candidates.entries()) {
|
|
751
|
+
if (!taken.has(index)) selected.push(plugin)
|
|
752
|
+
}
|
|
753
|
+
return { ...merged, plugins: selected }
|
|
754
|
+
}
|
|
755
|
+
|
|
756
|
+
function isNamedPlugin(plugin: PluginOption): plugin is { name: string } {
|
|
757
|
+
return (
|
|
758
|
+
typeof plugin === 'object' &&
|
|
759
|
+
plugin !== null &&
|
|
760
|
+
!Array.isArray(plugin) &&
|
|
761
|
+
!('then' in plugin && typeof plugin.then === 'function') &&
|
|
762
|
+
'name' in plugin &&
|
|
763
|
+
typeof plugin.name === 'string'
|
|
764
|
+
)
|
|
765
|
+
}
|
|
766
|
+
|
|
704
767
|
{{factories}}export default defineConfig({
|
|
705
768
|
resolve,
|
|
706
769
|
test: {
|
|
@@ -711,149 +774,166 @@ const resolve = {
|
|
|
711
774
|
}),
|
|
712
775
|
factories: Object.freeze({
|
|
713
776
|
src: Object.freeze({
|
|
714
|
-
core: `export
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
})
|
|
731
|
-
`,
|
|
732
|
-
browser: `export const srcBrowser = (): UserConfig => ({
|
|
733
|
-
resolve,
|
|
734
|
-
publicDir: false,
|
|
735
|
-
plugins: [outputBoundary('dist/src/browser'), environmentBoundary('src/browser')],
|
|
736
|
-
build: {
|
|
737
|
-
emptyOutDir: true,
|
|
738
|
-
sourcemap: true,
|
|
739
|
-
minify: false,
|
|
740
|
-
lib: {
|
|
741
|
-
entry: resolveWorkspacePath('src/browser/index.ts'),
|
|
742
|
-
formats: ['es'],
|
|
743
|
-
fileName: () => 'index.js',
|
|
777
|
+
core: `export function srcCore(override?: UserConfig): UserConfig {
|
|
778
|
+
const project: UserConfig = {
|
|
779
|
+
resolve,
|
|
780
|
+
publicDir: false,
|
|
781
|
+
build: {
|
|
782
|
+
emptyOutDir: true,
|
|
783
|
+
sourcemap: true,
|
|
784
|
+
minify: false,
|
|
785
|
+
rolldownOptions: { onLog: enforceBuildLog },
|
|
786
|
+
},
|
|
787
|
+
test: {
|
|
788
|
+
name: { label: 'src:core', color: 'magenta' },
|
|
789
|
+
include: ['tests/src/core/**/*.test.ts'],
|
|
790
|
+
setupFiles: ['./tests/setup.ts'],
|
|
791
|
+
environment: 'node',
|
|
792
|
+
browser: { enabled: false },
|
|
744
793
|
},
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
794
|
+
}
|
|
795
|
+
return mergeOverride(project, override)
|
|
796
|
+
}
|
|
797
|
+
`,
|
|
798
|
+
browser: `export function srcBrowser(override?: UserConfig): UserConfig {
|
|
799
|
+
const project: UserConfig = {
|
|
800
|
+
resolve,
|
|
801
|
+
publicDir: false,
|
|
802
|
+
plugins: [outputBoundary('dist/src/browser'), environmentBoundary('src/browser')],
|
|
803
|
+
build: {
|
|
804
|
+
emptyOutDir: true,
|
|
805
|
+
sourcemap: true,
|
|
806
|
+
minify: false,
|
|
807
|
+
lib: {
|
|
808
|
+
entry: resolveWorkspacePath('src/browser/index.ts'),
|
|
809
|
+
formats: ['es'],
|
|
810
|
+
fileName: () => 'index.js',
|
|
811
|
+
},
|
|
812
|
+
outDir: 'dist/src/browser',
|
|
813
|
+
rolldownOptions: {
|
|
814
|
+
onLog: enforceBuildLog,
|
|
815
|
+
{{external}}
|
|
749
816
|
{{output}}
|
|
817
|
+
},
|
|
750
818
|
},
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
{{exclude}} setupFiles: ['./tests/setup.ts', './tests/setupBrowser.ts'],
|
|
819
|
+
test: {
|
|
820
|
+
name: { label: 'src:browser', color: 'yellow' },
|
|
821
|
+
include: ['tests/src/browser/**/*.test.ts'],
|
|
822
|
+
{{exclude}} setupFiles: ['./tests/setup.ts', './tests/setupBrowser.ts'],
|
|
756
823
|
{{global}}
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
824
|
+
browser: {
|
|
825
|
+
enabled: true,
|
|
826
|
+
provider: playwright(browserOptions),
|
|
827
|
+
instances: [{ browser: 'chromium', headless: true }],
|
|
828
|
+
},
|
|
829
|
+
fileParallelism: false,
|
|
761
830
|
},
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
}
|
|
831
|
+
}
|
|
832
|
+
return mergeOverride(project, override)
|
|
833
|
+
}
|
|
765
834
|
`,
|
|
766
|
-
server: `export
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
835
|
+
server: `export function srcServer(override?: UserConfig): UserConfig {
|
|
836
|
+
const project: UserConfig = {
|
|
837
|
+
resolve,
|
|
838
|
+
publicDir: false,
|
|
839
|
+
plugins: [outputBoundary('dist/src/server'), environmentBoundary('src/server')],
|
|
840
|
+
build: {
|
|
841
|
+
emptyOutDir: true,
|
|
842
|
+
sourcemap: true,
|
|
843
|
+
minify: false,
|
|
844
|
+
lib: {
|
|
845
|
+
entry: resolveWorkspacePath('src/server/index.ts'),
|
|
846
|
+
formats: ['es', 'cjs'],
|
|
847
|
+
fileName: (format: string) => (format === 'es' ? 'index.js' : 'index.cjs'),
|
|
848
|
+
},
|
|
849
|
+
outDir: 'dist/src/server',
|
|
850
|
+
target: 'node22',
|
|
851
|
+
rolldownOptions: {
|
|
852
|
+
onLog: enforceBuildLog,
|
|
853
|
+
platform: 'node',
|
|
854
|
+
{{external}}
|
|
785
855
|
{{output}}
|
|
856
|
+
},
|
|
786
857
|
},
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
}
|
|
795
|
-
|
|
858
|
+
test: {
|
|
859
|
+
name: { label: 'src:server', color: 'red' },
|
|
860
|
+
include: ['tests/src/server/**/*.test.ts'],
|
|
861
|
+
{{exclude}} setupFiles: ['./tests/setup.ts', './tests/setupServer.ts'],
|
|
862
|
+
environment: 'node',
|
|
863
|
+
browser: { enabled: false },
|
|
864
|
+
},
|
|
865
|
+
}
|
|
866
|
+
return mergeOverride(project, override)
|
|
867
|
+
}
|
|
796
868
|
`,
|
|
797
|
-
bin: `export
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
869
|
+
bin: `export function srcBin(override?: UserConfig): UserConfig {
|
|
870
|
+
const project: UserConfig = {
|
|
871
|
+
resolve,
|
|
872
|
+
publicDir: false,
|
|
873
|
+
plugins: [outputBoundary('dist/bin')],
|
|
874
|
+
build: {
|
|
875
|
+
emptyOutDir: true,
|
|
876
|
+
sourcemap: true,
|
|
877
|
+
minify: false,
|
|
878
|
+
lib: {
|
|
879
|
+
entry: resolveWorkspacePath('${BIN_ENTRY_PATH}'),
|
|
880
|
+
formats: ['es'],
|
|
881
|
+
fileName: () => 'main.js',
|
|
882
|
+
},
|
|
883
|
+
outDir: 'dist/bin',
|
|
884
|
+
target: 'node22',
|
|
885
|
+
rolldownOptions: {
|
|
886
|
+
onLog: enforceBuildLog,
|
|
887
|
+
external: (id: string) =>
|
|
888
|
+
id.startsWith('node:') ||
|
|
889
|
+
id.startsWith('@orkestrel/') ||
|
|
890
|
+
id.startsWith('@src/') ||
|
|
891
|
+
peers.some((peer) => id === peer || id.startsWith(peer + '/')),
|
|
892
|
+
},
|
|
809
893
|
},
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
894
|
+
test: {
|
|
895
|
+
name: { label: 'src:bin', color: 'yellow' },
|
|
896
|
+
include: ['tests/src/bin/**/*.test.ts'],
|
|
897
|
+
setupFiles: ['./tests/setup.ts', './tests/setupServer.ts'],
|
|
898
|
+
environment: 'node',
|
|
899
|
+
browser: { enabled: false },
|
|
900
|
+
// A bin test drives the real executable over a real temporary repository, so it
|
|
901
|
+
// spends seconds in process startup and filesystem work rather than milliseconds.
|
|
902
|
+
// Vitest's five-second default clears one alone and times out under a full suite.
|
|
903
|
+
testTimeout: 15_000,
|
|
819
904
|
},
|
|
820
|
-
}
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
include: ['tests/src/bin/**/*.test.ts'],
|
|
824
|
-
setupFiles: ['./tests/setup.ts', './tests/setupServer.ts'],
|
|
825
|
-
environment: 'node',
|
|
826
|
-
browser: { enabled: false },
|
|
827
|
-
// A bin test drives the real executable over a real temporary repository, so it
|
|
828
|
-
// spends seconds in process startup and filesystem work rather than milliseconds.
|
|
829
|
-
// Vitest's five-second default clears one alone and times out under a full suite.
|
|
830
|
-
testTimeout: 15_000,
|
|
831
|
-
},
|
|
832
|
-
})
|
|
905
|
+
}
|
|
906
|
+
return mergeOverride(project, override)
|
|
907
|
+
}
|
|
833
908
|
`
|
|
834
909
|
}),
|
|
835
910
|
app: Object.freeze({
|
|
836
|
-
core: `export
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
}
|
|
911
|
+
core: `export function appCore(override?: UserConfig): UserConfig {
|
|
912
|
+
const project: UserConfig = {
|
|
913
|
+
resolve,
|
|
914
|
+
publicDir: false,
|
|
915
|
+
plugins: [environmentBoundary('app/core')],
|
|
916
|
+
test: {
|
|
917
|
+
name: { label: 'app:core', color: 'cyan' },
|
|
918
|
+
include: ['tests/app/core/**/*.test.ts'],
|
|
919
|
+
setupFiles: ['./tests/setup.ts'],
|
|
920
|
+
environment: 'node',
|
|
921
|
+
browser: { enabled: false },
|
|
922
|
+
},
|
|
923
|
+
}
|
|
924
|
+
return mergeOverride(project, override)
|
|
925
|
+
}
|
|
848
926
|
`,
|
|
849
|
-
browser: `function
|
|
850
|
-
const output =
|
|
851
|
-
|
|
927
|
+
browser: `export function appBrowser(override?: UserConfig): UserConfig {
|
|
928
|
+
const output = 'dist/app/browser'
|
|
929
|
+
const project: UserConfig = {
|
|
852
930
|
resolve,
|
|
853
|
-
|
|
931
|
+
plugins: [outputBoundary(output), environmentBoundary('app/browser'), vue()],
|
|
932
|
+
root: resolveWorkspacePath('app/browser'),
|
|
854
933
|
publicDir: false,
|
|
855
934
|
build: {
|
|
856
|
-
|
|
935
|
+
assetsInlineLimit: 0,
|
|
936
|
+
emptyOutDir: true,
|
|
857
937
|
outDir: resolveWorkspacePath(output),
|
|
858
938
|
rolldownOptions: {
|
|
859
939
|
onLog: enforceBuildLog,
|
|
@@ -874,160 +954,229 @@ const resolve = {
|
|
|
874
954
|
fileParallelism: false,
|
|
875
955
|
},
|
|
876
956
|
}
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
export function appBrowser(): UserConfig {
|
|
880
|
-
return applicationBrowser(false)
|
|
957
|
+
return mergeOverride(project, override)
|
|
881
958
|
}
|
|
882
959
|
{{showcaseFactory}}`,
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
960
|
+
showcase: `
|
|
961
|
+
export function appShowcase(override?: UserConfig): UserConfig {
|
|
962
|
+
const output = 'dist/showcase'
|
|
963
|
+
const showcase: UserConfig = {
|
|
964
|
+
plugins: [
|
|
965
|
+
outputBoundary(output),
|
|
966
|
+
viteSingleFile({
|
|
967
|
+
removeViteModuleLoader: true,
|
|
968
|
+
useRecommendedBuildConfig: true,
|
|
969
|
+
}),
|
|
970
|
+
{
|
|
971
|
+
name: 'orkestrel-showcase-html',
|
|
972
|
+
transformIndexHtml: {
|
|
973
|
+
order: 'post',
|
|
974
|
+
handler(html) {
|
|
975
|
+
const stamp = new Date().toISOString()
|
|
976
|
+
return html.replace(
|
|
977
|
+
'</head>',
|
|
978
|
+
'\t\t<meta name="build-id" content="' + stamp + '" />\\n\t</head>',
|
|
979
|
+
)
|
|
980
|
+
},
|
|
981
|
+
},
|
|
982
|
+
},
|
|
983
|
+
],
|
|
984
|
+
build: {
|
|
985
|
+
// The \`appBrowser\` factory sets \`assetsInlineLimit\` to 0, so every asset becomes
|
|
986
|
+
// its own file, and 4096 is Vite's own default put back. The \`viteSingleFile\`
|
|
987
|
+
// plugin overwrites the value while the \`useRecommendedBuildConfig\` option stays
|
|
988
|
+
// true, so this line takes effect only in a workspace that turns that option off.
|
|
989
|
+
assetsInlineLimit: 4096,
|
|
990
|
+
cssMinify: 'lightningcss',
|
|
991
|
+
minify: 'oxc',
|
|
992
|
+
modulePreload: false,
|
|
993
|
+
outDir: resolveWorkspacePath(output),
|
|
994
|
+
reportCompressedSize: false,
|
|
995
|
+
sourcemap: false,
|
|
996
|
+
target: 'esnext',
|
|
893
997
|
},
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
998
|
+
}
|
|
999
|
+
return appBrowser(mergeOverride(showcase, override))
|
|
1000
|
+
}
|
|
1001
|
+
`,
|
|
1002
|
+
server: `export function appServer(override?: UserConfig): UserConfig {
|
|
1003
|
+
const project: UserConfig = {
|
|
1004
|
+
resolve,
|
|
1005
|
+
publicDir: false,
|
|
1006
|
+
plugins: [outputBoundary('dist/app/server'), environmentBoundary('app/server')],
|
|
1007
|
+
build: {
|
|
1008
|
+
emptyOutDir: true,
|
|
1009
|
+
lib: {
|
|
1010
|
+
entry: resolveWorkspacePath('app/server/main.ts'),
|
|
1011
|
+
formats: ['cjs'],
|
|
1012
|
+
fileName: () => 'main.cjs',
|
|
1013
|
+
},
|
|
1014
|
+
outDir: resolveWorkspacePath('dist/app/server'),
|
|
1015
|
+
target: 'node22',
|
|
1016
|
+
rolldownOptions: {
|
|
1017
|
+
onLog: enforceBuildLog,
|
|
1018
|
+
external: (id: string) => id.startsWith('node:'),
|
|
1019
|
+
},
|
|
899
1020
|
},
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
}
|
|
908
|
-
|
|
1021
|
+
test: {
|
|
1022
|
+
name: { label: 'app:server', color: 'green' },
|
|
1023
|
+
include: ['tests/app/server/**/*.test.ts'],
|
|
1024
|
+
setupFiles: ['./tests/setup.ts', './tests/setupServer.ts'],
|
|
1025
|
+
environment: 'node',
|
|
1026
|
+
browser: { enabled: false },
|
|
1027
|
+
},
|
|
1028
|
+
}
|
|
1029
|
+
return mergeOverride(project, override)
|
|
1030
|
+
}
|
|
909
1031
|
`
|
|
910
1032
|
}),
|
|
911
|
-
policy: `export
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
}
|
|
1033
|
+
policy: `export function policy(override?: UserConfig): UserConfig {
|
|
1034
|
+
const project: UserConfig = {
|
|
1035
|
+
resolve,
|
|
1036
|
+
test: {
|
|
1037
|
+
name: { label: 'policy', color: 'white' },
|
|
1038
|
+
include: ['tests/policy.test.ts'],
|
|
1039
|
+
setupFiles: ['./tests/setup.ts'],
|
|
1040
|
+
environment: 'node',
|
|
1041
|
+
browser: { enabled: false },
|
|
1042
|
+
},
|
|
1043
|
+
}
|
|
1044
|
+
return mergeOverride(project, override)
|
|
1045
|
+
}
|
|
921
1046
|
`,
|
|
922
|
-
config: `export
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
}
|
|
1047
|
+
config: `export function config(override?: UserConfig): UserConfig {
|
|
1048
|
+
const project: UserConfig = {
|
|
1049
|
+
resolve,
|
|
1050
|
+
test: {
|
|
1051
|
+
name: { label: 'config', color: 'yellow' },
|
|
1052
|
+
include: ['tests/config.test.ts'],
|
|
1053
|
+
setupFiles: ['./tests/setup.ts'],
|
|
1054
|
+
environment: 'node',
|
|
1055
|
+
browser: { enabled: false },
|
|
1056
|
+
// A config test validates every target wrapper, spawns the real linter twice under
|
|
1057
|
+
// 15-second child caps, and rolls one face up through the compiler and the extractor it
|
|
1058
|
+
// spawns, so this budget clears the capped pair with room for a contended host.
|
|
1059
|
+
testTimeout: 60_000,
|
|
1060
|
+
},
|
|
1061
|
+
}
|
|
1062
|
+
return mergeOverride(project, override)
|
|
1063
|
+
}
|
|
936
1064
|
`,
|
|
937
|
-
setup: `export
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
}
|
|
1065
|
+
setup: `export function setup(override?: UserConfig): UserConfig {
|
|
1066
|
+
const project: UserConfig = {
|
|
1067
|
+
resolve,
|
|
1068
|
+
test: {
|
|
1069
|
+
name: { label: 'setup', color: 'white' },
|
|
1070
|
+
include: ['tests/setup*.test.ts'],
|
|
1071
|
+
setupFiles: ['./tests/setup.ts'],
|
|
1072
|
+
environment: 'node',
|
|
1073
|
+
browser: { enabled: false },
|
|
1074
|
+
},
|
|
1075
|
+
}
|
|
1076
|
+
return mergeOverride(project, override)
|
|
1077
|
+
}
|
|
947
1078
|
`,
|
|
948
|
-
guides: `export
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
}
|
|
1079
|
+
guides: `export function guides(override?: UserConfig): UserConfig {
|
|
1080
|
+
const project: UserConfig = {
|
|
1081
|
+
resolve,
|
|
1082
|
+
test: {
|
|
1083
|
+
name: { label: 'guides', color: 'green' },
|
|
1084
|
+
include: ['${GUIDES_TEST_PATH}'],
|
|
1085
|
+
exclude: ['tests/src/**/*.test.ts', 'tests/app/**/*.test.ts', 'tests/setup.test.ts'],
|
|
1086
|
+
setupFiles: ['./tests/setup.ts'],
|
|
1087
|
+
environment: 'node',
|
|
1088
|
+
browser: { enabled: false },
|
|
1089
|
+
},
|
|
1090
|
+
}
|
|
1091
|
+
return mergeOverride(project, override)
|
|
1092
|
+
}
|
|
959
1093
|
`,
|
|
960
1094
|
conformance: `// Where this package drifts from the official tooling it stays compatible with.
|
|
961
1095
|
// The subject is this package, so the proof is hermetic and stays in \`npm test\`.
|
|
962
|
-
export
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
}
|
|
1096
|
+
export function conformance(override?: UserConfig): UserConfig {
|
|
1097
|
+
const project: UserConfig = {
|
|
1098
|
+
resolve,
|
|
1099
|
+
test: {
|
|
1100
|
+
name: { label: 'conformance', color: 'magenta' },
|
|
1101
|
+
include: ['${CONFORMANCE_TEST_PATH}'],
|
|
1102
|
+
setupFiles: ['./tests/setup.ts'],
|
|
1103
|
+
environment: 'node',
|
|
1104
|
+
browser: { enabled: false },
|
|
1105
|
+
},
|
|
1106
|
+
}
|
|
1107
|
+
return mergeOverride(project, override)
|
|
1108
|
+
}
|
|
972
1109
|
`,
|
|
973
1110
|
service: `// The caller prepares the live external services before this project.
|
|
974
1111
|
// \`tests/setupService.ts\` verifies readiness, and the project stays out of \`npm test\`
|
|
975
1112
|
// because a real service answers it.
|
|
976
|
-
export
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
}
|
|
1113
|
+
export function service(override?: UserConfig): UserConfig {
|
|
1114
|
+
const project: UserConfig = {
|
|
1115
|
+
resolve,
|
|
1116
|
+
test: {
|
|
1117
|
+
name: { label: 'service', color: 'red' },
|
|
1118
|
+
include: ['${SERVICE_TEST_INCLUDE}'],
|
|
1119
|
+
setupFiles: ['./tests/setup.ts', './tests/setupService.ts'],
|
|
1120
|
+
environment: 'node',
|
|
1121
|
+
browser: { enabled: false },
|
|
1122
|
+
testTimeout: 120_000,
|
|
1123
|
+
hookTimeout: 120_000,
|
|
1124
|
+
fileParallelism: false,
|
|
1125
|
+
},
|
|
1126
|
+
}
|
|
1127
|
+
return mergeOverride(project, override)
|
|
1128
|
+
}
|
|
989
1129
|
`,
|
|
990
|
-
distribution: `export
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
}
|
|
1130
|
+
distribution: `export function distribution(override?: UserConfig): UserConfig {
|
|
1131
|
+
const project: UserConfig = {
|
|
1132
|
+
resolve,
|
|
1133
|
+
test: {
|
|
1134
|
+
name: { label: 'distribution', color: 'cyan' },
|
|
1135
|
+
include: ['${DISTRIBUTION_TEST_PATH}'],
|
|
1136
|
+
setupFiles: ['./tests/setup.ts'],
|
|
1137
|
+
environment: 'node',
|
|
1138
|
+
testTimeout: 120_000,
|
|
1139
|
+
hookTimeout: 120_000,
|
|
1140
|
+
fileParallelism: false,
|
|
1141
|
+
},
|
|
1142
|
+
}
|
|
1143
|
+
return mergeOverride(project, override)
|
|
1144
|
+
}
|
|
1002
1145
|
`,
|
|
1003
1146
|
probe: `// A workbench, not a proof. No gate selects this project. Run in test mode by the
|
|
1004
1147
|
// \`test:probe\` script, it collects \`tmp/probe/**/*.test.ts\`. Run in benchmark mode by the
|
|
1005
1148
|
// \`test:bench\` script, the same workbench also collects \`tests/**/*.test.ts\` for a \`bench\` block,
|
|
1006
1149
|
// so a suite may carry a bench beside its ordinary tests without a second project. The mode
|
|
1007
1150
|
// guard around each \`bench\` call keeps it out of test mode, so it never executes there.
|
|
1008
|
-
export
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
}
|
|
1151
|
+
export function probe(override?: UserConfig): UserConfig {
|
|
1152
|
+
const project: UserConfig = {
|
|
1153
|
+
resolve,
|
|
1154
|
+
test: {
|
|
1155
|
+
name: { label: 'probe', color: 'black' },
|
|
1156
|
+
include: ['tmp/probe/**/*.test.ts'],
|
|
1157
|
+
setupFiles: ['./tests/setup.ts'],
|
|
1158
|
+
environment: 'node',
|
|
1159
|
+
browser: { enabled: false },
|
|
1160
|
+
fileParallelism: false,
|
|
1161
|
+
pool: 'threads',
|
|
1162
|
+
benchmark: { include: ['tmp/probe/**/*.test.ts', 'tests/**/*.test.ts'] },
|
|
1163
|
+
},
|
|
1164
|
+
}
|
|
1165
|
+
return mergeOverride(project, override)
|
|
1166
|
+
}
|
|
1021
1167
|
`,
|
|
1022
|
-
integration: `export
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
}
|
|
1168
|
+
integration: `export function integration(override?: UserConfig): UserConfig {
|
|
1169
|
+
const project: UserConfig = {
|
|
1170
|
+
resolve,
|
|
1171
|
+
test: {
|
|
1172
|
+
name: { label: 'integration', color: 'blue' },
|
|
1173
|
+
include: ['${INTEGRATION_TEST_PATH}'],
|
|
1174
|
+
setupFiles: ['./tests/setup.ts'],
|
|
1175
|
+
{{global}} environment: 'node',
|
|
1176
|
+
},
|
|
1177
|
+
}
|
|
1178
|
+
return mergeOverride(project, override)
|
|
1179
|
+
}
|
|
1031
1180
|
`
|
|
1032
1181
|
}),
|
|
1033
1182
|
tsconfigs: Object.freeze({
|
|
@@ -1155,12 +1304,12 @@ export const probe = (): UserConfig => ({
|
|
|
1155
1304
|
}),
|
|
1156
1305
|
vites: Object.freeze({
|
|
1157
1306
|
src: Object.freeze({
|
|
1158
|
-
core: `import { defineConfig
|
|
1307
|
+
core: `import { defineConfig } from 'vite'
|
|
1159
1308
|
import { declarationRollup, environmentBoundary, outputBoundary } from '../helpers.js'
|
|
1160
1309
|
import { peers, srcCore, resolveWorkspacePath } from '../../vite.config.ts'
|
|
1161
1310
|
|
|
1162
1311
|
export default defineConfig(
|
|
1163
|
-
|
|
1312
|
+
srcCore({
|
|
1164
1313
|
publicDir: false,
|
|
1165
1314
|
plugins: [
|
|
1166
1315
|
outputBoundary('dist/src/core'),
|
|
@@ -1187,14 +1336,14 @@ export default defineConfig(
|
|
|
1187
1336
|
}),
|
|
1188
1337
|
)
|
|
1189
1338
|
`,
|
|
1190
|
-
browser: `import { defineConfig
|
|
1339
|
+
browser: `import { defineConfig } from 'vite'
|
|
1191
1340
|
import { declarationRollup, rewriteCoreSpecifier } from '../helpers.js'
|
|
1192
1341
|
import { srcBrowser, resolveWorkspacePath } from '../../vite.config.ts'
|
|
1193
1342
|
|
|
1194
1343
|
// The roll-up reaches src/core through a specifier the tarball does not carry, so the rewrite
|
|
1195
1344
|
// externalizes core through the package's own published root export, on the final roll-up alone.
|
|
1196
1345
|
export default defineConfig(
|
|
1197
|
-
|
|
1346
|
+
srcBrowser({
|
|
1198
1347
|
plugins: [
|
|
1199
1348
|
declarationRollup({
|
|
1200
1349
|
project: resolveWorkspacePath('configs/src/tsconfig.browser.json'),
|
|
@@ -1204,14 +1353,14 @@ export default defineConfig(
|
|
|
1204
1353
|
}),
|
|
1205
1354
|
)
|
|
1206
1355
|
`,
|
|
1207
|
-
server: `import { defineConfig
|
|
1356
|
+
server: `import { defineConfig } from 'vite'
|
|
1208
1357
|
import { declarationRollup, rewriteCoreSpecifier } from '../helpers.js'
|
|
1209
1358
|
import { srcServer, resolveWorkspacePath } from '../../vite.config.ts'
|
|
1210
1359
|
|
|
1211
1360
|
// The roll-up reaches src/core through a specifier the tarball does not carry, so the rewrite
|
|
1212
1361
|
// externalizes core through the package's own published root export, on the final roll-up alone.
|
|
1213
1362
|
export default defineConfig(
|
|
1214
|
-
|
|
1363
|
+
srcServer({
|
|
1215
1364
|
plugins: [
|
|
1216
1365
|
declarationRollup({
|
|
1217
1366
|
project: resolveWorkspacePath('configs/src/tsconfig.server.json'),
|
|
@@ -1222,7 +1371,7 @@ export default defineConfig(
|
|
|
1222
1371
|
)
|
|
1223
1372
|
`
|
|
1224
1373
|
}),
|
|
1225
|
-
bin: `import { defineConfig
|
|
1374
|
+
bin: `import { defineConfig } from 'vite'
|
|
1226
1375
|
import { srcBin } from '../../vite.config.ts'
|
|
1227
1376
|
|
|
1228
1377
|
// The \`scaffold\` executable build — a single ESM lib file, no declarations (an
|
|
@@ -1231,7 +1380,7 @@ import { srcBin } from '../../vite.config.ts'
|
|
|
1231
1380
|
// \`output.paths\` rewriting the externalized \`@src/*\` specifiers to the built sibling
|
|
1232
1381
|
// src environments (relative to \`dist/bin/\`), so the emitted bin resolves at runtime.
|
|
1233
1382
|
export default defineConfig(
|
|
1234
|
-
|
|
1383
|
+
srcBin({
|
|
1235
1384
|
build: {
|
|
1236
1385
|
rolldownOptions: {
|
|
1237
1386
|
output: {
|
|
@@ -4999,14 +5148,14 @@ function blueprintToRootVite(blueprint) {
|
|
|
4999
5148
|
const core = blueprint.src.includes("core");
|
|
5000
5149
|
factories.push((0, _orkestrel_template.fillTemplate)(CONFIG_TEMPLATES.factories.src.browser, {
|
|
5001
5150
|
external: core ? `external: (id: string) =>
|
|
5002
|
-
|
|
5003
|
-
|
|
5004
|
-
|
|
5005
|
-
|
|
5006
|
-
|
|
5007
|
-
output: core ? "
|
|
5008
|
-
exclude: core ? "
|
|
5009
|
-
global: blueprint.global ? "
|
|
5151
|
+
id === '@src/core' ||
|
|
5152
|
+
id.startsWith('@orkestrel/') ||
|
|
5153
|
+
peers.some((peer) => id === peer || id.startsWith(peer + '/')),` : `external: (id: string) =>
|
|
5154
|
+
id.startsWith('@orkestrel/') ||
|
|
5155
|
+
peers.some((peer) => id === peer || id.startsWith(peer + '/')),`,
|
|
5156
|
+
output: core ? " output: { paths: { '@src/core': '../core/index.js' } }," : " output: {},",
|
|
5157
|
+
exclude: core ? " exclude: ['tests/src/core/**/*.test.ts'],\n" : "",
|
|
5158
|
+
global: blueprint.global ? " globalSetup: ['./tests/setupGlobal.ts'],\n" : ""
|
|
5010
5159
|
}));
|
|
5011
5160
|
projects.push("srcBrowser");
|
|
5012
5161
|
}
|
|
@@ -5014,26 +5163,26 @@ function blueprintToRootVite(blueprint) {
|
|
|
5014
5163
|
const core = blueprint.src.includes("core");
|
|
5015
5164
|
factories.push((0, _orkestrel_template.fillTemplate)(CONFIG_TEMPLATES.factories.src.server, {
|
|
5016
5165
|
external: core ? `external: (id: string) =>
|
|
5017
|
-
|
|
5018
|
-
|
|
5019
|
-
|
|
5020
|
-
|
|
5021
|
-
|
|
5022
|
-
|
|
5023
|
-
|
|
5024
|
-
output: core ? `\t\t\toutput: [
|
|
5025
|
-
|
|
5026
|
-
|
|
5027
|
-
|
|
5028
|
-
|
|
5029
|
-
|
|
5030
|
-
|
|
5031
|
-
|
|
5032
|
-
|
|
5033
|
-
|
|
5034
|
-
|
|
5035
|
-
|
|
5036
|
-
exclude: core ? "
|
|
5166
|
+
id === '@src/core' ||
|
|
5167
|
+
id.startsWith('node:') ||
|
|
5168
|
+
id.startsWith('@orkestrel/') ||
|
|
5169
|
+
peers.some((peer) => id === peer || id.startsWith(peer + '/')),` : `external: (id: string) =>
|
|
5170
|
+
id.startsWith('node:') ||
|
|
5171
|
+
id.startsWith('@orkestrel/') ||
|
|
5172
|
+
peers.some((peer) => id === peer || id.startsWith(peer + '/')),`,
|
|
5173
|
+
output: core ? `\t\t\t\toutput: [
|
|
5174
|
+
{
|
|
5175
|
+
format: 'es',
|
|
5176
|
+
entryFileNames: 'index.js',
|
|
5177
|
+
paths: { '@src/core': '../core/index.js' },
|
|
5178
|
+
},
|
|
5179
|
+
{
|
|
5180
|
+
format: 'cjs',
|
|
5181
|
+
entryFileNames: 'index.cjs',
|
|
5182
|
+
paths: { '@src/core': '../core/index.cjs' },
|
|
5183
|
+
},
|
|
5184
|
+
],` : " output: {},",
|
|
5185
|
+
exclude: core ? " exclude: ['tests/src/core/**/*.test.ts'],\n" : ""
|
|
5037
5186
|
}));
|
|
5038
5187
|
projects.push("srcServer");
|
|
5039
5188
|
}
|
|
@@ -5046,57 +5195,8 @@ function blueprintToRootVite(blueprint) {
|
|
|
5046
5195
|
projects.push("appCore");
|
|
5047
5196
|
}
|
|
5048
5197
|
if (blueprint.app.includes("browser")) {
|
|
5049
|
-
const
|
|
5050
|
-
|
|
5051
|
-
viteSingleFile({
|
|
5052
|
-
removeViteModuleLoader: true,
|
|
5053
|
-
useRecommendedBuildConfig: true,
|
|
5054
|
-
}),
|
|
5055
|
-
{
|
|
5056
|
-
name: 'orkestrel-showcase-html',
|
|
5057
|
-
transformIndexHtml: {
|
|
5058
|
-
order: 'post',
|
|
5059
|
-
handler(html) {
|
|
5060
|
-
const stamp = new Date().toISOString()
|
|
5061
|
-
return html.replace(
|
|
5062
|
-
'</head>',
|
|
5063
|
-
'\t\t<meta name="build-id" content="' + stamp + '" />\\n\t</head>',
|
|
5064
|
-
)
|
|
5065
|
-
},
|
|
5066
|
-
},
|
|
5067
|
-
},
|
|
5068
|
-
]
|
|
5069
|
-
: []
|
|
5070
|
-
` : "";
|
|
5071
|
-
const plugins = machinery.showcase ? `\t\tplugins: [
|
|
5072
|
-
outputBoundary(output),
|
|
5073
|
-
environmentBoundary('app/browser'),
|
|
5074
|
-
vue(),
|
|
5075
|
-
...showcasePlugins,
|
|
5076
|
-
],
|
|
5077
|
-
` : " plugins: [outputBoundary(output), environmentBoundary('app/browser'), vue()],\n";
|
|
5078
|
-
const showcaseBuild = machinery.showcase ? `\t\t\t...(showcase
|
|
5079
|
-
? {
|
|
5080
|
-
cssMinify: 'lightningcss',
|
|
5081
|
-
minify: 'oxc',
|
|
5082
|
-
modulePreload: false,
|
|
5083
|
-
reportCompressedSize: false,
|
|
5084
|
-
sourcemap: false,
|
|
5085
|
-
target: 'esnext',
|
|
5086
|
-
}
|
|
5087
|
-
: { assetsInlineLimit: 0 }),
|
|
5088
|
-
` : " assetsInlineLimit: 0,\n";
|
|
5089
|
-
const showcaseFactory = machinery.showcase ? `
|
|
5090
|
-
export function appShowcase(): UserConfig {
|
|
5091
|
-
return applicationBrowser(true)
|
|
5092
|
-
}
|
|
5093
|
-
` : "";
|
|
5094
|
-
factories.push((0, _orkestrel_template.fillTemplate)(CONFIG_TEMPLATES.factories.app.browser, {
|
|
5095
|
-
plugins,
|
|
5096
|
-
showcasePlugins,
|
|
5097
|
-
showcaseBuild,
|
|
5098
|
-
showcaseFactory
|
|
5099
|
-
}));
|
|
5198
|
+
const showcaseFactory = machinery.showcase ? CONFIG_TEMPLATES.factories.app.showcase : "";
|
|
5199
|
+
factories.push((0, _orkestrel_template.fillTemplate)(CONFIG_TEMPLATES.factories.app.browser, { showcaseFactory }));
|
|
5100
5200
|
projects.push("appBrowser");
|
|
5101
5201
|
}
|
|
5102
5202
|
if (blueprint.app.includes("server")) {
|
|
@@ -5128,7 +5228,7 @@ export function appShowcase(): UserConfig {
|
|
|
5128
5228
|
projects.push("distribution");
|
|
5129
5229
|
}
|
|
5130
5230
|
if (blueprint.integration) {
|
|
5131
|
-
factories.push((0, _orkestrel_template.fillTemplate)(CONFIG_TEMPLATES.factories.integration, { global: blueprint.global ? "
|
|
5231
|
+
factories.push((0, _orkestrel_template.fillTemplate)(CONFIG_TEMPLATES.factories.integration, { global: blueprint.global ? " globalSetup: ['./tests/setupGlobal.ts'],\n" : "" }));
|
|
5132
5232
|
projects.push("integration");
|
|
5133
5233
|
}
|
|
5134
5234
|
factories.push(CONFIG_TEMPLATES.factories.probe);
|
|
@@ -5144,7 +5244,6 @@ ${projects.map((project) => `\t\t\t${project},`).join("\n")}
|
|
|
5144
5244
|
"outputBoundary"
|
|
5145
5245
|
].filter((helper) => body.includes(helper));
|
|
5146
5246
|
return (0, _orkestrel_template.fillTemplate)(CONFIG_TEMPLATES.root.vite, {
|
|
5147
|
-
viteTypes: machinery.showcase ? "PluginOption, UserConfig" : "UserConfig",
|
|
5148
5247
|
imports: imports.length === 0 ? "" : `${imports.join("\n")}\n`,
|
|
5149
5248
|
helpers: helpers.length === 0 ? "" : `import { ${helpers.join(", ")} } from './configs/helpers.js'\n`,
|
|
5150
5249
|
browsers: machinery.browser ? "import { resolveBrowser, resolvePinnedBrowser } from './configs/browsers.js'\n" : "",
|