create-koppajs 1.2.2 → 1.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (78) hide show
  1. package/CHANGELOG.md +37 -0
  2. package/README.md +12 -10
  3. package/bin/create-koppajs.js +0 -14
  4. package/package.json +4 -4
  5. package/template/README.md +19 -206
  6. package/template/_gitignore +0 -3
  7. package/template/index.html +1 -1
  8. package/template/package.json +9 -46
  9. package/template/public/favicon.png +0 -0
  10. package/template/public/koppajs-logo.png +0 -0
  11. package/template/src/app-view.kpa +1 -3
  12. package/template/tsconfig.json +2 -9
  13. package/template-overlays/router/README.md +25 -200
  14. package/template-overlays/router/index.html +1 -1
  15. package/template-overlays/router/package.json +10 -47
  16. package/template-overlays/router/src/app-view.kpa +21 -78
  17. package/template-overlays/router/src/home-page.kpa +23 -60
  18. package/template-overlays/router/src/main.ts +0 -9
  19. package/template-overlays/router/src/not-found-page.kpa +16 -48
  20. package/template-overlays/router/src/router-page.kpa +34 -69
  21. package/template-overlays/router/src/style.css +5 -29
  22. package/template/AI_CONSTITUTION.md +0 -50
  23. package/template/ARCHITECTURE.md +0 -84
  24. package/template/CHANGELOG.md +0 -35
  25. package/template/CONTRIBUTING.md +0 -89
  26. package/template/DECISION_HIERARCHY.md +0 -32
  27. package/template/DEVELOPMENT_RULES.md +0 -57
  28. package/template/LICENSE +0 -201
  29. package/template/RELEASE.md +0 -227
  30. package/template/ROADMAP.md +0 -34
  31. package/template/TESTING_STRATEGY.md +0 -96
  32. package/template/_editorconfig +0 -12
  33. package/template/_github/instructions/ai-workflow.md +0 -33
  34. package/template/_github/workflows/ci.yml +0 -41
  35. package/template/_github/workflows/release.yml +0 -58
  36. package/template/_husky/commit-msg +0 -8
  37. package/template/_husky/pre-commit +0 -1
  38. package/template/_prettierignore +0 -7
  39. package/template/commitlint.config.mjs +0 -6
  40. package/template/docs/adr/0001-keep-the-starter-minimal.md +0 -32
  41. package/template/docs/adr/0002-adopt-a-living-meta-layer.md +0 -30
  42. package/template/docs/adr/0003-rely-on-upstream-kpa-es-module-output.md +0 -32
  43. package/template/docs/adr/0004-adopt-an-automated-quality-baseline.md +0 -31
  44. package/template/docs/adr/0005-adopt-a-tag-driven-release-baseline.md +0 -45
  45. package/template/docs/adr/0006-adopt-commit-message-conventions.md +0 -39
  46. package/template/docs/adr/README.md +0 -37
  47. package/template/docs/adr/TEMPLATE.md +0 -18
  48. package/template/docs/architecture/module-boundaries.md +0 -47
  49. package/template/docs/meta/maintenance.md +0 -40
  50. package/template/docs/quality/quality-gates.md +0 -39
  51. package/template/docs/specs/README.md +0 -36
  52. package/template/docs/specs/TEMPLATE.md +0 -34
  53. package/template/docs/specs/app-bootstrap.md +0 -46
  54. package/template/docs/specs/counter-component.md +0 -48
  55. package/template/docs/specs/quality-workflow.md +0 -62
  56. package/template/eslint.config.mjs +0 -54
  57. package/template/playwright.config.ts +0 -31
  58. package/template/pnpm-lock.yaml +0 -3777
  59. package/template/prettier.config.mjs +0 -6
  60. package/template/public/favicon.svg +0 -15
  61. package/template/tests/e2e/app.spec.ts +0 -18
  62. package/template/tests/integration/main-bootstrap.test.ts +0 -33
  63. package/template/vite.config.d.mts +0 -5
  64. package/template/vitest.config.mjs +0 -19
  65. package/template-overlays/router/ARCHITECTURE.md +0 -86
  66. package/template-overlays/router/CHANGELOG.md +0 -50
  67. package/template-overlays/router/DEVELOPMENT_RULES.md +0 -57
  68. package/template-overlays/router/ROADMAP.md +0 -34
  69. package/template-overlays/router/TESTING_STRATEGY.md +0 -67
  70. package/template-overlays/router/docs/adr/0001-keep-the-starter-minimal.md +0 -32
  71. package/template-overlays/router/docs/architecture/module-boundaries.md +0 -39
  72. package/template-overlays/router/docs/meta/maintenance.md +0 -38
  73. package/template-overlays/router/docs/specs/README.md +0 -19
  74. package/template-overlays/router/docs/specs/app-bootstrap.md +0 -42
  75. package/template-overlays/router/docs/specs/router-navigation.md +0 -41
  76. package/template-overlays/router/pnpm-lock.yaml +0 -3786
  77. package/template-overlays/router/tests/e2e/app.spec.ts +0 -38
  78. package/template-overlays/router/tests/integration/main-bootstrap.test.ts +0 -150
@@ -1,62 +0,0 @@
1
- # Spec: Quality workflow
2
-
3
- ## Status
4
-
5
- Approved
6
-
7
- ## Purpose
8
-
9
- Keep the starter's tooling, tests, and contributor workflow consistent enough that regressions are caught early without turning a minimal example into a heavyweight platform.
10
-
11
- ## Behavior
12
-
13
- - The repository exposes a fast local validation path through `pnpm check`.
14
- - The repository exposes a fuller validation path through `pnpm validate`, which adds a real-browser smoke test.
15
- - Staged files run through a fast `lint-staged` pre-commit hook.
16
- - Commit messages are validated by `commitlint` in a `commit-msg` hook.
17
- - Source, config, and test changes are checked by ESLint, Prettier, TypeScript, and Vitest.
18
- - The real UI smoke path is checked by Playwright against `vite preview`.
19
- - CI runs the same full validation flow as local contributors.
20
- - Tagged releases rerun the full validation flow and verify tag/version alignment before a GitHub Release is created.
21
- - Stylelint is intentionally absent until the repository has a credible way to lint embedded `.kpa` CSS without covering only the least relevant styling surface.
22
-
23
- ## Inputs
24
-
25
- - Source, config, test, and documentation changes
26
- - Staged files at commit time
27
- - Commit messages at commit time
28
- - Pull requests and pushes that trigger CI
29
- - Version, changelog, and tag pushes that trigger the release workflow
30
-
31
- ## Outputs
32
-
33
- - Consistent formatting on supported file types
34
- - Conventional commit history for maintainable review and release preparation
35
- - Type-safe source and TypeScript tooling files
36
- - Automated confidence for bootstrap wiring and the starter UI smoke path
37
- - A guarded GitHub release path that fails when the pushed tag does not match `package.json`
38
- - Fast feedback before commit and in CI
39
-
40
- ## Constraints
41
-
42
- - Hooks must stay fast enough for normal local use.
43
- - Playwright coverage must remain focused on smoke-level user journeys until the UI surface grows.
44
- - Tooling should stay aligned with the starter's actual risk profile rather than generic best-practice checklists.
45
- - Release automation must stay consistent with the repository remaining `private`; it may create GitHub Releases but must not imply npm publishing.
46
- - Commit rules should stay simple enough that contributors can apply them without release tooling knowledge.
47
-
48
- ## Edge cases
49
-
50
- - If browser binaries are not installed locally, contributors must install Chromium before running `pnpm test:e2e` or `pnpm validate`.
51
- - If Stylelint is introduced later, it must cover the meaningful styling surface rather than only `src/style.css`.
52
- - If the UI grows beyond a simple smoke surface, expand Playwright coverage deliberately and update this spec.
53
- - If a pushed tag does not match `package.json`, the release workflow must fail before creating a release artifact.
54
- - Auto-generated merge, revert, `fixup!`, and `squash!` commits may be exempted by the hook logic.
55
-
56
- ## Acceptance criteria
57
-
58
- - `pnpm check` runs lint, format verification, type checking, Vitest, and build successfully on a clean checkout.
59
- - `pnpm validate` reuses the built output to run the Playwright smoke test successfully.
60
- - A commit with a staged lint or formatting error is blocked by the pre-commit hook.
61
- - A non-conventional commit message is blocked by the `commit-msg` hook.
62
- - A pushed `vX.Y.Z` tag is rejected by release automation when `package.json` contains a different version.
@@ -1,54 +0,0 @@
1
- import js from "@eslint/js";
2
- import globals from "globals";
3
- import { fileURLToPath } from "node:url";
4
- import tseslint from "typescript-eslint";
5
-
6
- const tsconfigRootDir = fileURLToPath(new URL(".", import.meta.url));
7
-
8
- export default tseslint.config(
9
- {
10
- ignores: [
11
- ".ai/**",
12
- "coverage/**",
13
- "dist/**",
14
- "node_modules/**",
15
- "playwright-report/**",
16
- "test-results/**",
17
- ],
18
- },
19
- {
20
- files: ["**/*.{js,mjs,cjs}"],
21
- extends: [js.configs.recommended],
22
- languageOptions: {
23
- globals: {
24
- ...globals.node,
25
- },
26
- },
27
- },
28
- {
29
- files: ["**/*.{ts,mts,cts}"],
30
- extends: [...tseslint.configs.recommendedTypeChecked],
31
- languageOptions: {
32
- parserOptions: {
33
- projectService: true,
34
- tsconfigRootDir,
35
- },
36
- },
37
- },
38
- {
39
- files: ["src/**/*.ts"],
40
- languageOptions: {
41
- globals: {
42
- ...globals.browser,
43
- },
44
- },
45
- },
46
- {
47
- files: ["tests/**/*.ts", "*.config.ts"],
48
- languageOptions: {
49
- globals: {
50
- ...globals.node,
51
- },
52
- },
53
- },
54
- );
@@ -1,31 +0,0 @@
1
- import { defineConfig, devices } from "@playwright/test";
2
-
3
- const port = 4173;
4
-
5
- export default defineConfig({
6
- testDir: "./tests/e2e",
7
- fullyParallel: true,
8
- forbidOnly: Boolean(process.env.CI),
9
- retries: process.env.CI ? 2 : 0,
10
- reporter: process.env.CI ? "github" : "list",
11
- use: {
12
- baseURL: `http://127.0.0.1:${port}`,
13
- screenshot: "only-on-failure",
14
- trace: "on-first-retry",
15
- video: "retain-on-failure",
16
- },
17
- webServer: {
18
- command: "pnpm serve:e2e",
19
- url: `http://127.0.0.1:${port}`,
20
- reuseExistingServer: !process.env.CI,
21
- timeout: 120_000,
22
- },
23
- projects: [
24
- {
25
- name: "chromium",
26
- use: {
27
- ...devices["Desktop Chrome"],
28
- },
29
- },
30
- ],
31
- });