create-harper 1.7.4 → 1.8.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.
Files changed (146) hide show
  1. package/lib/constants/frameworks.js +20 -0
  2. package/lib/constants/helpMessage.js +2 -2
  3. package/package.json +6 -2
  4. package/template-react/README.md +6 -2
  5. package/template-react/_gitignore +1 -2
  6. package/template-react/config.yaml +16 -3
  7. package/template-react/package.json +9 -7
  8. package/template-react/src/App.jsx +1 -5
  9. package/template-react/vite.config.js +2 -2
  10. package/template-react-ssr/README.md +124 -0
  11. package/template-react-ssr/_aiignore +1 -0
  12. package/template-react-ssr/_env +1 -0
  13. package/template-react-ssr/_env.example +1 -0
  14. package/template-react-ssr/_github/workflow/deploy.yaml +33 -0
  15. package/template-react-ssr/_gitignore +148 -0
  16. package/template-react-ssr/_nvmrc +1 -0
  17. package/template-react-ssr/config.yaml +42 -0
  18. package/template-react-ssr/eslint.config.js +23 -0
  19. package/template-react-ssr/graphql.config.yml +3 -0
  20. package/template-react-ssr/index.html +13 -0
  21. package/template-react-ssr/package.json +32 -0
  22. package/template-react-ssr/public/react.svg +14 -0
  23. package/template-react-ssr/public/vite.svg +42 -0
  24. package/template-react-ssr/resources/README.md +11 -0
  25. package/template-react-ssr/schemas/README.md +11 -0
  26. package/template-react-ssr/schemas/jsdocTypes.js +5 -0
  27. package/template-react-ssr/src/App.jsx +31 -0
  28. package/template-react-ssr/src/counter.js +7 -0
  29. package/template-react-ssr/src/entry-client.jsx +13 -0
  30. package/template-react-ssr/src/entry-server.jsx +18 -0
  31. package/template-react-ssr/src/style.css +96 -0
  32. package/template-react-ssr/src/vite-env.d.ts +9 -0
  33. package/template-react-ssr/test/counter.test.js +15 -0
  34. package/template-react-ssr/vite.config.js +22 -0
  35. package/template-react-ts/README.md +6 -2
  36. package/template-react-ts/_gitignore +1 -2
  37. package/template-react-ts/config.yaml +16 -3
  38. package/template-react-ts/package.json +10 -8
  39. package/template-react-ts/vite.config.ts +2 -2
  40. package/template-react-ts-ssr/README.md +132 -0
  41. package/template-react-ts-ssr/_aiignore +1 -0
  42. package/template-react-ts-ssr/_env +1 -0
  43. package/template-react-ts-ssr/_env.example +1 -0
  44. package/template-react-ts-ssr/_github/workflow/deploy.yaml +33 -0
  45. package/template-react-ts-ssr/_gitignore +148 -0
  46. package/template-react-ts-ssr/_nvmrc +1 -0
  47. package/template-react-ts-ssr/config.yaml +43 -0
  48. package/template-react-ts-ssr/eslint.config.js +23 -0
  49. package/template-react-ts-ssr/graphql.config.yml +3 -0
  50. package/template-react-ts-ssr/index.html +13 -0
  51. package/template-react-ts-ssr/package.json +36 -0
  52. package/template-react-ts-ssr/public/react.svg +14 -0
  53. package/template-react-ts-ssr/public/vite.svg +42 -0
  54. package/template-react-ts-ssr/resources/README.md +11 -0
  55. package/template-react-ts-ssr/schemas/README.md +11 -0
  56. package/template-react-ts-ssr/schemas/globalTypes.d.ts +5 -0
  57. package/template-react-ts-ssr/schemas/types.ts +5 -0
  58. package/template-react-ts-ssr/src/App.tsx +35 -0
  59. package/template-react-ts-ssr/src/counter.ts +7 -0
  60. package/template-react-ts-ssr/src/entry-client.tsx +13 -0
  61. package/template-react-ts-ssr/src/entry-server.tsx +17 -0
  62. package/template-react-ts-ssr/src/style.css +96 -0
  63. package/template-react-ts-ssr/src/vite-env.d.ts +9 -0
  64. package/template-react-ts-ssr/test/counter.test.ts +15 -0
  65. package/template-react-ts-ssr/tsconfig.json +34 -0
  66. package/template-react-ts-ssr/vite.config.ts +22 -0
  67. package/template-vanilla/README.md +5 -1
  68. package/template-vanilla-ts/README.md +5 -1
  69. package/template-vue/README.md +6 -2
  70. package/template-vue/_gitignore +1 -2
  71. package/template-vue/config.yaml +16 -3
  72. package/template-vue/package.json +9 -7
  73. package/template-vue/src/App.vue +1 -9
  74. package/template-vue/vite.config.js +1 -1
  75. package/template-vue-ssr/README.md +124 -0
  76. package/template-vue-ssr/_aiignore +1 -0
  77. package/template-vue-ssr/_env +1 -0
  78. package/template-vue-ssr/_env.example +1 -0
  79. package/template-vue-ssr/_github/workflow/deploy.yaml +33 -0
  80. package/template-vue-ssr/_gitignore +148 -0
  81. package/template-vue-ssr/_nvmrc +1 -0
  82. package/template-vue-ssr/config.yaml +42 -0
  83. package/template-vue-ssr/eslint.config.js +23 -0
  84. package/template-vue-ssr/graphql.config.yml +3 -0
  85. package/template-vue-ssr/index.html +13 -0
  86. package/template-vue-ssr/package.json +31 -0
  87. package/template-vue-ssr/public/react.svg +14 -0
  88. package/template-vue-ssr/public/vite.svg +42 -0
  89. package/template-vue-ssr/public/vue.svg +9 -0
  90. package/template-vue-ssr/resources/README.md +11 -0
  91. package/template-vue-ssr/schemas/README.md +11 -0
  92. package/template-vue-ssr/schemas/jsdocTypes.js +5 -0
  93. package/template-vue-ssr/src/App.vue +35 -0
  94. package/template-vue-ssr/src/counter.js +7 -0
  95. package/template-vue-ssr/src/entry-client.js +7 -0
  96. package/template-vue-ssr/src/entry-server.js +14 -0
  97. package/template-vue-ssr/src/style.css +96 -0
  98. package/template-vue-ssr/test/counter.test.js +15 -0
  99. package/template-vue-ssr/vite.config.js +22 -0
  100. package/template-vue-ts/README.md +6 -2
  101. package/template-vue-ts/_gitignore +1 -2
  102. package/template-vue-ts/config.yaml +16 -3
  103. package/template-vue-ts/package.json +8 -6
  104. package/template-vue-ts/vite.config.ts +1 -1
  105. package/template-vue-ts-ssr/README.md +132 -0
  106. package/template-vue-ts-ssr/_aiignore +1 -0
  107. package/template-vue-ts-ssr/_env +1 -0
  108. package/template-vue-ts-ssr/_env.example +1 -0
  109. package/template-vue-ts-ssr/_github/workflow/deploy.yaml +33 -0
  110. package/template-vue-ts-ssr/_gitignore +148 -0
  111. package/template-vue-ts-ssr/_nvmrc +1 -0
  112. package/template-vue-ts-ssr/config.yaml +43 -0
  113. package/template-vue-ts-ssr/eslint.config.js +23 -0
  114. package/template-vue-ts-ssr/graphql.config.yml +3 -0
  115. package/template-vue-ts-ssr/index.html +13 -0
  116. package/template-vue-ts-ssr/package.json +34 -0
  117. package/template-vue-ts-ssr/public/react.svg +14 -0
  118. package/template-vue-ts-ssr/public/vite.svg +42 -0
  119. package/template-vue-ts-ssr/public/vue.svg +9 -0
  120. package/template-vue-ts-ssr/resources/README.md +11 -0
  121. package/template-vue-ts-ssr/schemas/README.md +11 -0
  122. package/template-vue-ts-ssr/schemas/globalTypes.d.ts +5 -0
  123. package/template-vue-ts-ssr/schemas/types.ts +5 -0
  124. package/template-vue-ts-ssr/src/App.vue +43 -0
  125. package/template-vue-ts-ssr/src/counter.ts +7 -0
  126. package/template-vue-ts-ssr/src/entry-client.ts +7 -0
  127. package/template-vue-ts-ssr/src/entry-server.ts +13 -0
  128. package/template-vue-ts-ssr/src/style.css +96 -0
  129. package/template-vue-ts-ssr/src/vite-env.d.ts +15 -0
  130. package/template-vue-ts-ssr/test/counter.test.ts +15 -0
  131. package/template-vue-ts-ssr/tsconfig.json +33 -0
  132. package/template-vue-ts-ssr/vite.config.ts +22 -0
  133. package/template-react/deploy-template/config.yaml +0 -10
  134. package/template-react/deploy-template/fastify/static.js +0 -14
  135. package/template-react/deploy-template/package.json +0 -5
  136. package/template-react-ts/deploy-template/config.yaml +0 -10
  137. package/template-react-ts/deploy-template/fastify/static.js +0 -14
  138. package/template-react-ts/deploy-template/package.json +0 -5
  139. package/template-vue/deploy-template/config.yaml +0 -10
  140. package/template-vue/deploy-template/fastify/static.js +0 -14
  141. package/template-vue/deploy-template/package.json +0 -5
  142. package/template-vue-ts/deploy-template/config.yaml +0 -10
  143. package/template-vue-ts/deploy-template/fastify/static.js +0 -14
  144. package/template-vue-ts/deploy-template/package.json +0 -5
  145. /package/{template-react → template-react-ts-ssr}/public/typescript.svg +0 -0
  146. /package/{template-vue → template-vue-ts-ssr}/public/typescript.svg +0 -0
@@ -0,0 +1,34 @@
1
+ {
2
+ "name": "your-package-name-here",
3
+ "version": "0.0.0",
4
+ "type": "module",
5
+ "repository": "github:HarperFast/create-harper",
6
+ "scripts": {
7
+ "agent:run": "npx -y @harperfast/agent@latest",
8
+ "agent:skills:update": "npx -y skills@latest add harperfast/skills --all --yes",
9
+ "start": "harper run .",
10
+ "dev": "harper dev .",
11
+ "lint": "eslint .",
12
+ "format": "prettier --write .",
13
+ "test": "node --test test/*.test.ts",
14
+ "test:watch": "node --watch --test test/*.test.ts",
15
+ "build": "vite build",
16
+ "deploy": "harper deploy_component . restart=true replicated=true"
17
+ },
18
+ "dependencies": {
19
+ "@harperfast/schema-codegen": "^1.0.10",
20
+ "@harperfast/vite": "^1.1.0",
21
+ "@vitejs/plugin-vue": "^6.0.5",
22
+ "vite": "^8.0.0",
23
+ "vue": "^3.5.29"
24
+ },
25
+ "devDependencies": {
26
+ "@eslint/js": "^10.0.1",
27
+ "@types/node": "^24.10.1",
28
+ "eslint": "^10.0.2",
29
+ "globals": "^17.4.0",
30
+ "prettier": "^3.8.1",
31
+ "typescript": "~6.0.0",
32
+ "vue-tsc": "^3.2.5"
33
+ }
34
+ }
@@ -0,0 +1,14 @@
1
+ <svg
2
+ width="100%"
3
+ height="100%"
4
+ viewBox="-10.5 -9.45 21 18.9"
5
+ fill="none"
6
+ xmlns="http://www.w3.org/2000/svg"
7
+ >
8
+ <circle cx="0" cy="0" r="2" fill="#58c4dc"></circle>
9
+ <g stroke="#58c4dc" stroke-width="1" fill="none">
10
+ <ellipse rx="10" ry="4.5"></ellipse>
11
+ <ellipse rx="10" ry="4.5" transform="rotate(60)"></ellipse>
12
+ <ellipse rx="10" ry="4.5" transform="rotate(120)"></ellipse>
13
+ </g>
14
+ </svg>
@@ -0,0 +1,42 @@
1
+ <svg
2
+ xmlns="http://www.w3.org/2000/svg"
3
+ aria-hidden="true"
4
+ role="img"
5
+ class="iconify iconify--logos"
6
+ width="31.88"
7
+ height="32"
8
+ preserveAspectRatio="xMidYMid meet"
9
+ viewBox="0 0 256 257"
10
+ >
11
+ <defs>
12
+ <linearGradient
13
+ id="IconifyId1813088fe1fbc01fb466"
14
+ x1="-.828%"
15
+ x2="57.636%"
16
+ y1="7.652%"
17
+ y2="78.411%"
18
+ >
19
+ <stop offset="0%" stop-color="#41D1FF"></stop>
20
+ <stop offset="100%" stop-color="#BD34FE"></stop>
21
+ </linearGradient>
22
+ <linearGradient
23
+ id="IconifyId1813088fe1fbc01fb467"
24
+ x1="43.376%"
25
+ x2="50.316%"
26
+ y1="2.242%"
27
+ y2="89.03%"
28
+ >
29
+ <stop offset="0%" stop-color="#FFEA83"></stop>
30
+ <stop offset="8.333%" stop-color="#FFDD35"></stop>
31
+ <stop offset="100%" stop-color="#FFA800"></stop>
32
+ </linearGradient>
33
+ </defs>
34
+ <path
35
+ fill="url(#IconifyId1813088fe1fbc01fb466)"
36
+ d="M255.153 37.938L134.897 252.976c-2.483 4.44-8.862 4.466-11.382.048L.875 37.958c-2.746-4.814 1.371-10.646 6.827-9.67l120.385 21.517a6.537 6.537 0 0 0 2.322-.004l117.867-21.483c5.438-.991 9.574 4.796 6.877 9.62Z"
37
+ ></path>
38
+ <path
39
+ fill="url(#IconifyId1813088fe1fbc01fb467)"
40
+ d="M185.432.063L96.44 17.501a3.268 3.268 0 0 0-2.634 3.014l-5.474 92.456a3.268 3.268 0 0 0 3.997 3.378l24.777-5.718c2.318-.535 4.413 1.507 3.936 3.838l-7.361 36.047c-.495 2.426 1.782 4.5 4.151 3.78l15.304-4.649c2.372-.72 4.652 1.36 4.15 3.788l-11.698 56.621c-.732 3.542 3.979 5.473 5.943 2.437l1.313-2.028l72.516-144.72c1.215-2.423-.88-5.186-3.54-4.672l-25.505 4.922c-2.396.462-4.435-1.77-3.759-4.114l16.646-57.705c.677-2.35-1.37-4.583-3.769-4.113Z"
41
+ ></path>
42
+ </svg>
@@ -0,0 +1,9 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 196.3 170">
2
+ <path
3
+ fill="#41B883"
4
+ d="m120.8 0-22.6 39.2L75.6 0H0l98.2 170L196.3 0h-75.5z"
5
+ /><path
6
+ fill="#34495E"
7
+ d="m120.8 0-22.6 39.2L75.6 0h-31l53.6 92.8L151.8 0h-31z"
8
+ />
9
+ </svg>
@@ -0,0 +1,11 @@
1
+ # Resources
2
+
3
+ The [schemas you define in .GraphQL files](../.agents/skills/harper-best-practices/rules/adding-tables-with-schemas.md) will [automatically stand-up REST APIs](../.agents/skills/harper-best-practices/rules/automatic-apis.md).
4
+
5
+ But you can [extend your tables with custom logic](../.agents/skills/harper-best-practices/rules/extending-tables.md) and [create your own resources](../.agents/skills/harper-best-practices/rules/custom-resources.md) in this directory.
6
+
7
+ ## Want to read more?
8
+
9
+ Check out the rest of the "skills" documentation!
10
+
11
+ [Harper Best Practices Skill](../.agents/skills/harper-best-practices/SKILL.md)
@@ -0,0 +1,11 @@
1
+ # Schemas
2
+
3
+ Your schemas are defined in `.graphql` files within this `schemas` directory. These files contain the structure and types for your database tables, allowing Harper to automatically generate REST APIs for CRUD operations.
4
+
5
+ Take a look at the [Adding Tables with Schemas](../.agents/skills/harper-best-practices/rules/adding-tables-with-schemas.md) to learn more!
6
+
7
+ ## Want to read more?
8
+
9
+ Check out the rest of the "skills" documentation!
10
+
11
+ [Harper Best Practices Skill](../.agents/skills/harper-best-practices/SKILL.md)
@@ -0,0 +1,5 @@
1
+ /**
2
+ Generated from your schema files
3
+ Manual changes will be lost!
4
+ > harper dev .
5
+ */
@@ -0,0 +1,5 @@
1
+ /**
2
+ Generated from your schema files
3
+ Manual changes will be lost!
4
+ > harper dev .
5
+ */
@@ -0,0 +1,43 @@
1
+ <script setup lang="ts">
2
+ import typescriptLogo from '/typescript.svg';
3
+ import viteLogo from '/vite.svg';
4
+ import vueLogo from '/vue.svg';
5
+ import { increment } from '@/counter.ts';
6
+ import { ref } from 'vue';
7
+
8
+ const counter = ref(0);
9
+ const countUp = () => {
10
+ counter.value = increment(counter.value);
11
+ };
12
+ </script>
13
+
14
+ <template>
15
+ <div>
16
+ <a href="https://vite.dev" target="_blank" rel="noopener noreferrer">
17
+ <img :src="viteLogo" class="logo" alt="Vite logo" />
18
+ </a>
19
+ <a
20
+ href="https://www.typescriptlang.org/"
21
+ target="_blank"
22
+ rel="noopener noreferrer"
23
+ >
24
+ <img :src="typescriptLogo" class="logo vanilla" alt="TypeScript logo" />
25
+ </a>
26
+ <a href="https://vuejs.org/" target="_blank" rel="noopener noreferrer">
27
+ <img :src="vueLogo" class="logo vue" alt="Vue logo" />
28
+ </a>
29
+ <h1>Vite + TypeScript + Vue</h1>
30
+ <p>Wow, look at this!</p>
31
+ <div class="card">
32
+ <button id="counter" type="button" @click="countUp">
33
+ count is {{ counter }}
34
+ </button>
35
+ </div>
36
+ </div>
37
+ </template>
38
+
39
+ <style scoped>
40
+ .logo.vue:hover {
41
+ filter: drop-shadow(0 0 2em #42b883aa);
42
+ }
43
+ </style>
@@ -0,0 +1,7 @@
1
+ export function increment(value: number) {
2
+ return value + 1;
3
+ }
4
+
5
+ export function decrement(value: number) {
6
+ return value - 1;
7
+ }
@@ -0,0 +1,7 @@
1
+ import App from '@/App.vue';
2
+ import { createSSRApp } from 'vue';
3
+
4
+ import './style.css';
5
+
6
+ // `createSSRApp` hydrates the server-rendered markup. (A client-only app would use `createApp`.)
7
+ createSSRApp(App).mount('#app');
@@ -0,0 +1,13 @@
1
+ import App from '@/App.vue';
2
+ import { createSSRApp } from 'vue';
3
+ import { renderToString } from 'vue/server-renderer';
4
+
5
+ /**
6
+ * Server render entry. The Vite Harper plugin calls this for HTML navigations and injects the
7
+ * returned markup into the `<!--ssr-outlet-->` placeholder in index.html.
8
+ *
9
+ * @param _url The request URL — use it to drive routing/data loading per request.
10
+ */
11
+ export function render(_url: string): Promise<string> {
12
+ return renderToString(createSSRApp(App));
13
+ }
@@ -0,0 +1,96 @@
1
+ :root {
2
+ font-family: system-ui, Avenir, Helvetica, Arial, sans-serif;
3
+ line-height: 1.5;
4
+ font-weight: 400;
5
+
6
+ color-scheme: light dark;
7
+ color: rgba(255, 255, 255, 0.87);
8
+ background-color: #242424;
9
+
10
+ font-synthesis: none;
11
+ text-rendering: optimizeLegibility;
12
+ -webkit-font-smoothing: antialiased;
13
+ -moz-osx-font-smoothing: grayscale;
14
+ }
15
+
16
+ a {
17
+ font-weight: 500;
18
+ color: #646cff;
19
+ text-decoration: inherit;
20
+ }
21
+ a:hover {
22
+ color: #535bf2;
23
+ }
24
+
25
+ body {
26
+ margin: 0;
27
+ display: flex;
28
+ place-items: center;
29
+ min-width: 320px;
30
+ min-height: 100vh;
31
+ }
32
+
33
+ h1 {
34
+ font-size: 3.2em;
35
+ line-height: 1.1;
36
+ }
37
+
38
+ #app {
39
+ max-width: 1280px;
40
+ margin: 0 auto;
41
+ padding: 2rem;
42
+ text-align: center;
43
+ }
44
+
45
+ .logo {
46
+ height: 6em;
47
+ padding: 1.5em;
48
+ will-change: filter;
49
+ transition: filter 300ms;
50
+ }
51
+ .logo:hover {
52
+ filter: drop-shadow(0 0 2em #646cffaa);
53
+ }
54
+ .logo.vanilla:hover {
55
+ filter: drop-shadow(0 0 2em #3178c6aa);
56
+ }
57
+
58
+ .card {
59
+ padding: 2em;
60
+ }
61
+
62
+ .read-the-docs {
63
+ color: #888;
64
+ }
65
+
66
+ button {
67
+ border-radius: 8px;
68
+ border: 1px solid transparent;
69
+ padding: 0.6em 1.2em;
70
+ font-size: 1em;
71
+ font-weight: 500;
72
+ font-family: inherit;
73
+ background-color: #1a1a1a;
74
+ cursor: pointer;
75
+ transition: border-color 0.25s;
76
+ }
77
+ button:hover {
78
+ border-color: #646cff;
79
+ }
80
+ button:focus,
81
+ button:focus-visible {
82
+ outline: 4px auto -webkit-focus-ring-color;
83
+ }
84
+
85
+ @media (prefers-color-scheme: light) {
86
+ :root {
87
+ color: #213547;
88
+ background-color: #ffffff;
89
+ }
90
+ a:hover {
91
+ color: #747bff;
92
+ }
93
+ button {
94
+ background-color: #f9f9f9;
95
+ }
96
+ }
@@ -0,0 +1,15 @@
1
+ /// <reference types="vite/client" />
2
+
3
+ interface ImportMetaEnv {
4
+ readonly VITE_EXAMPLE_ENV_VAR: string;
5
+ }
6
+
7
+ interface ImportMeta {
8
+ readonly env: ImportMetaEnv;
9
+ }
10
+
11
+ declare module '*.vue' {
12
+ import type { DefineComponent } from 'vue';
13
+ const component: DefineComponent<{}, {}, any>;
14
+ export default component;
15
+ }
@@ -0,0 +1,15 @@
1
+ import { strictEqual } from 'node:assert/strict';
2
+ import { test } from 'node:test';
3
+ import { decrement, increment } from '../src/counter.ts';
4
+
5
+ test('increment function', () => {
6
+ strictEqual(increment(0), 1);
7
+ strictEqual(increment(1), 2);
8
+ strictEqual(increment(-1), 0);
9
+ });
10
+
11
+ test('decrement function', () => {
12
+ strictEqual(decrement(0), -1);
13
+ strictEqual(decrement(1), 0);
14
+ strictEqual(decrement(-1), -2);
15
+ });
@@ -0,0 +1,33 @@
1
+ {
2
+ "compilerOptions": {
3
+ "target": "ES2022",
4
+ "useDefineForClassFields": true,
5
+ "module": "ESNext",
6
+ "lib": ["ES2022", "DOM", "DOM.Iterable"],
7
+ "types": ["vite/client"],
8
+ "skipLibCheck": true,
9
+ "forceConsistentCasingInFileNames": true,
10
+ "baseUrl": ".",
11
+ "paths": {
12
+ "@/*": [
13
+ "./src/*"
14
+ ]
15
+ },
16
+
17
+ /* Bundler mode */
18
+ "moduleResolution": "bundler",
19
+ "allowImportingTsExtensions": true,
20
+ "verbatimModuleSyntax": true,
21
+ "moduleDetection": "force",
22
+ "noEmit": true,
23
+
24
+ /* Linting */
25
+ "strict": true,
26
+ "noUnusedLocals": true,
27
+ "noUnusedParameters": true,
28
+ "erasableSyntaxOnly": true,
29
+ "noFallthroughCasesInSwitch": true,
30
+ "noUncheckedSideEffectImports": true
31
+ },
32
+ "include": ["src/**/*.ts", "src/**/*.tsx", "src/**/*.vue"]
33
+ }
@@ -0,0 +1,22 @@
1
+ import vue from '@vitejs/plugin-vue';
2
+ import path from 'node:path';
3
+ import { defineConfig } from 'vite';
4
+
5
+ // https://vite.dev/config/
6
+ export default defineConfig({
7
+ plugins: [
8
+ vue(),
9
+ ],
10
+ resolve: {
11
+ alias: {
12
+ '@': path.resolve(import.meta.dirname, './src'),
13
+ },
14
+ },
15
+ build: {
16
+ outDir: 'dist',
17
+ emptyOutDir: true,
18
+ rolldownOptions: {
19
+ external: ['**/*.test.*', '**/*.spec.*'],
20
+ },
21
+ },
22
+ });
@@ -1,10 +0,0 @@
1
- fastifyRoutes:
2
- files: fastify/*.js
3
-
4
- rest: true
5
-
6
- graphqlSchema:
7
- files: 'schemas/*.graphql'
8
-
9
- jsResource:
10
- files: 'resources/*.js'
@@ -1,14 +0,0 @@
1
- import fastifyStatic from '@fastify/static';
2
- import { join } from 'path';
3
-
4
- export default async (fastify) => {
5
- fastify.register(fastifyStatic, {
6
- root: join(import.meta.dirname, '../web'),
7
- maxAge: '30d',
8
- immutable: true,
9
- });
10
-
11
- fastify.get('/', function(req, reply) {
12
- reply.sendFile('index.html', { maxAge: '1m', immutable: false });
13
- });
14
- };
@@ -1,5 +0,0 @@
1
- {
2
- "dependencies": {
3
- "@fastify/static": "^9.0.0"
4
- }
5
- }
@@ -1,10 +0,0 @@
1
- fastifyRoutes:
2
- files: fastify/*.js
3
-
4
- rest: true
5
-
6
- graphqlSchema:
7
- files: 'schemas/*.graphql'
8
-
9
- jsResource:
10
- files: 'resources/*.ts'
@@ -1,14 +0,0 @@
1
- import fastifyStatic from '@fastify/static';
2
- import { join } from 'path';
3
-
4
- export default async (fastify) => {
5
- fastify.register(fastifyStatic, {
6
- root: join(import.meta.dirname, '../web'),
7
- maxAge: '30d',
8
- immutable: true,
9
- });
10
-
11
- fastify.get('/', function(req, reply) {
12
- reply.sendFile('index.html', { maxAge: '1m', immutable: false });
13
- });
14
- };
@@ -1,5 +0,0 @@
1
- {
2
- "dependencies": {
3
- "@fastify/static": "^9.0.0"
4
- }
5
- }
@@ -1,10 +0,0 @@
1
- fastifyRoutes:
2
- files: fastify/*.js
3
-
4
- rest: true
5
-
6
- graphqlSchema:
7
- files: 'schemas/*.graphql'
8
-
9
- jsResource:
10
- files: 'resources/*.js'
@@ -1,14 +0,0 @@
1
- import fastifyStatic from '@fastify/static';
2
- import { join } from 'path';
3
-
4
- export default async (fastify) => {
5
- fastify.register(fastifyStatic, {
6
- root: join(import.meta.dirname, '../web'),
7
- maxAge: '30d',
8
- immutable: true,
9
- });
10
-
11
- fastify.get('/', function(req, reply) {
12
- reply.sendFile('index.html', { maxAge: '1m', immutable: false });
13
- });
14
- };
@@ -1,5 +0,0 @@
1
- {
2
- "dependencies": {
3
- "@fastify/static": "^9.0.0"
4
- }
5
- }
@@ -1,10 +0,0 @@
1
- fastifyRoutes:
2
- files: fastify/*.js
3
-
4
- rest: true
5
-
6
- graphqlSchema:
7
- files: 'schemas/*.graphql'
8
-
9
- jsResource:
10
- files: 'resources/*.ts'
@@ -1,14 +0,0 @@
1
- import fastifyStatic from '@fastify/static';
2
- import { join } from 'path';
3
-
4
- export default async (fastify) => {
5
- fastify.register(fastifyStatic, {
6
- root: join(import.meta.dirname, '../web'),
7
- maxAge: '30d',
8
- immutable: true,
9
- });
10
-
11
- fastify.get('/', function(req, reply) {
12
- reply.sendFile('index.html', { maxAge: '1m', immutable: false });
13
- });
14
- };
@@ -1,5 +0,0 @@
1
- {
2
- "dependencies": {
3
- "@fastify/static": "^9.0.0"
4
- }
5
- }