create-cedar-app 6.0.2 → 6.0.3-next.275

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 (154) hide show
  1. package/database-overlays/neon-postgres/api/package.json +3 -3
  2. package/database-overlays/pglite/api/package.json +3 -3
  3. package/dist/create-cedar-app.js +446 -468
  4. package/package.json +13 -15
  5. package/templates/js/api/jsconfig.json +2 -2
  6. package/templates/js/api/package.json +12 -6
  7. package/templates/js/api/src/directives/requireAuth/requireAuth.js +1 -1
  8. package/templates/js/api/src/directives/skipAuth/skipAuth.js +1 -1
  9. package/templates/js/api/src/lib/auth.js +2 -2
  10. package/templates/js/api/src/lib/db.js +3 -1
  11. package/templates/js/package.json +12 -7
  12. package/templates/js/scripts/jsconfig.json +1 -2
  13. package/templates/js/web/jsconfig.json +1 -2
  14. package/templates/js/web/package.json +13 -9
  15. package/templates/js/web/src/pages/FatalErrorPage/FatalErrorPage.jsx +0 -1
  16. package/templates/js/web/src/pages/NotFoundPage/NotFoundPage.jsx +0 -1
  17. package/templates/js/web/vite.config.js +11 -3
  18. package/templates/overlays/{esm/npm → npm}/package.json +8 -8
  19. package/templates/overlays/{esm/pnpm → pnpm}/package.json +7 -7
  20. package/templates/overlays/{esm/pnpm → pnpm}/pnpm-workspace.yaml +1 -1
  21. package/templates/overlays/{esm/yarn → yarn}/package.json +8 -8
  22. package/templates/ts/api/package.json +12 -6
  23. package/templates/ts/api/src/directives/requireAuth/requireAuth.ts +1 -1
  24. package/templates/ts/api/src/directives/skipAuth/skipAuth.ts +1 -1
  25. package/templates/ts/api/src/lib/auth.ts +2 -2
  26. package/templates/ts/api/src/lib/db.ts +3 -1
  27. package/templates/ts/api/tsconfig.json +1 -0
  28. package/templates/ts/eslint.config.js +11 -0
  29. package/templates/ts/package.json +12 -7
  30. package/templates/ts/scripts/tsconfig.json +0 -1
  31. package/templates/ts/web/package.json +13 -9
  32. package/templates/ts/web/vite.config.ts +11 -3
  33. package/templates/esm-js/.cedar/README.md +0 -44
  34. package/templates/esm-js/.editorconfig +0 -10
  35. package/templates/esm-js/.env +0 -15
  36. package/templates/esm-js/.env.defaults +0 -19
  37. package/templates/esm-js/.env.example +0 -4
  38. package/templates/esm-js/.vscode/extensions.json +0 -14
  39. package/templates/esm-js/.vscode/launch.json +0 -56
  40. package/templates/esm-js/.vscode/settings.json +0 -11
  41. package/templates/esm-js/.vscode/tasks.json +0 -29
  42. package/templates/esm-js/README.md +0 -17
  43. package/templates/esm-js/api/db/schema.prisma +0 -29
  44. package/templates/esm-js/api/jsconfig.json +0 -41
  45. package/templates/esm-js/api/package.json +0 -19
  46. package/templates/esm-js/api/prisma.config.cjs +0 -12
  47. package/templates/esm-js/api/src/directives/requireAuth/requireAuth.js +0 -22
  48. package/templates/esm-js/api/src/directives/requireAuth/requireAuth.test.js +0 -18
  49. package/templates/esm-js/api/src/directives/skipAuth/skipAuth.js +0 -16
  50. package/templates/esm-js/api/src/directives/skipAuth/skipAuth.test.js +0 -10
  51. package/templates/esm-js/api/src/functions/graphql.js +0 -19
  52. package/templates/esm-js/api/src/graphql/.keep +0 -0
  53. package/templates/esm-js/api/src/lib/auth.js +0 -32
  54. package/templates/esm-js/api/src/lib/db.js +0 -46
  55. package/templates/esm-js/api/src/lib/logger.js +0 -17
  56. package/templates/esm-js/api/src/services/.keep +0 -0
  57. package/templates/esm-js/cedar.toml +0 -26
  58. package/templates/esm-js/gitignore.template +0 -27
  59. package/templates/esm-js/graphql.config.cjs +0 -11
  60. package/templates/esm-js/package.json +0 -33
  61. package/templates/esm-js/prettier.config.cjs +0 -18
  62. package/templates/esm-js/scripts/.keep +0 -0
  63. package/templates/esm-js/scripts/jsconfig.json +0 -60
  64. package/templates/esm-js/scripts/seed.js +0 -27
  65. package/templates/esm-js/web/index.html +0 -15
  66. package/templates/esm-js/web/jsconfig.json +0 -53
  67. package/templates/esm-js/web/package.json +0 -30
  68. package/templates/esm-js/web/public/README.md +0 -43
  69. package/templates/esm-js/web/public/favicon.png +0 -0
  70. package/templates/esm-js/web/public/robots.txt +0 -2
  71. package/templates/esm-js/web/src/App.jsx +0 -16
  72. package/templates/esm-js/web/src/Routes.jsx +0 -20
  73. package/templates/esm-js/web/src/components/.keep +0 -0
  74. package/templates/esm-js/web/src/entry.client.jsx +0 -35
  75. package/templates/esm-js/web/src/index.css +0 -0
  76. package/templates/esm-js/web/src/layouts/.keep +0 -0
  77. package/templates/esm-js/web/src/pages/FatalErrorPage/FatalErrorPage.jsx +0 -58
  78. package/templates/esm-js/web/src/pages/NotFoundPage/NotFoundPage.jsx +0 -45
  79. package/templates/esm-js/web/vite.config.js +0 -15
  80. package/templates/esm-ts/.cedar/README.md +0 -44
  81. package/templates/esm-ts/.editorconfig +0 -10
  82. package/templates/esm-ts/.env +0 -15
  83. package/templates/esm-ts/.env.defaults +0 -19
  84. package/templates/esm-ts/.env.example +0 -4
  85. package/templates/esm-ts/.vscode/extensions.json +0 -14
  86. package/templates/esm-ts/.vscode/launch.json +0 -56
  87. package/templates/esm-ts/.vscode/settings.json +0 -11
  88. package/templates/esm-ts/.vscode/tasks.json +0 -29
  89. package/templates/esm-ts/README.md +0 -17
  90. package/templates/esm-ts/api/db/schema.prisma +0 -29
  91. package/templates/esm-ts/api/package.json +0 -19
  92. package/templates/esm-ts/api/prisma.config.cjs +0 -12
  93. package/templates/esm-ts/api/src/directives/requireAuth/requireAuth.test.ts +0 -18
  94. package/templates/esm-ts/api/src/directives/requireAuth/requireAuth.ts +0 -25
  95. package/templates/esm-ts/api/src/directives/skipAuth/skipAuth.test.ts +0 -10
  96. package/templates/esm-ts/api/src/directives/skipAuth/skipAuth.ts +0 -16
  97. package/templates/esm-ts/api/src/functions/graphql.ts +0 -19
  98. package/templates/esm-ts/api/src/graphql/.keep +0 -0
  99. package/templates/esm-ts/api/src/lib/auth.ts +0 -32
  100. package/templates/esm-ts/api/src/lib/db.ts +0 -46
  101. package/templates/esm-ts/api/src/lib/logger.ts +0 -17
  102. package/templates/esm-ts/api/src/services/.keep +0 -0
  103. package/templates/esm-ts/api/tsconfig.json +0 -27
  104. package/templates/esm-ts/cedar.toml +0 -26
  105. package/templates/esm-ts/eslint.config.js +0 -3
  106. package/templates/esm-ts/gitignore.template +0 -27
  107. package/templates/esm-ts/graphql.config.cjs +0 -11
  108. package/templates/esm-ts/package.json +0 -33
  109. package/templates/esm-ts/prettier.config.cjs +0 -18
  110. package/templates/esm-ts/scripts/.keep +0 -0
  111. package/templates/esm-ts/scripts/seed.ts +0 -27
  112. package/templates/esm-ts/scripts/tsconfig.json +0 -35
  113. package/templates/esm-ts/web/index.html +0 -15
  114. package/templates/esm-ts/web/package.json +0 -30
  115. package/templates/esm-ts/web/public/README.md +0 -43
  116. package/templates/esm-ts/web/public/favicon.png +0 -0
  117. package/templates/esm-ts/web/public/robots.txt +0 -2
  118. package/templates/esm-ts/web/src/App.tsx +0 -22
  119. package/templates/esm-ts/web/src/Routes.tsx +0 -20
  120. package/templates/esm-ts/web/src/components/.keep +0 -0
  121. package/templates/esm-ts/web/src/entry.client.tsx +0 -35
  122. package/templates/esm-ts/web/src/index.css +0 -0
  123. package/templates/esm-ts/web/src/layouts/.keep +0 -0
  124. package/templates/esm-ts/web/src/pages/FatalErrorPage/FatalErrorPage.tsx +0 -57
  125. package/templates/esm-ts/web/src/pages/NotFoundPage/NotFoundPage.tsx +0 -44
  126. package/templates/esm-ts/web/tsconfig.json +0 -45
  127. package/templates/esm-ts/web/vite.config.ts +0 -15
  128. package/templates/js/api/jest.config.js +0 -8
  129. package/templates/js/eslint.config.mjs +0 -3
  130. package/templates/js/jest.config.js +0 -8
  131. package/templates/js/web/jest.config.js +0 -8
  132. package/templates/overlays/cjs/npm/package-lock.json +0 -29174
  133. package/templates/overlays/cjs/npm/package.json +0 -31
  134. package/templates/overlays/cjs/pnpm/package.json +0 -32
  135. package/templates/overlays/cjs/pnpm/pnpm-lock.yaml +0 -18340
  136. package/templates/overlays/cjs/pnpm/pnpm-workspace.yaml +0 -23
  137. package/templates/overlays/cjs/yarn/package.json +0 -73
  138. package/templates/overlays/cjs/yarn/yarn.lock +0 -19092
  139. package/templates/overlays/esm/npm/package-lock.json +0 -29578
  140. package/templates/overlays/esm/pnpm/pnpm-lock.yaml +0 -18819
  141. package/templates/overlays/esm/yarn/.yarnrc.yml +0 -17
  142. package/templates/overlays/esm/yarn/yarn.lock +0 -19377
  143. package/templates/ts/api/jest.config.js +0 -8
  144. package/templates/ts/eslint.config.mjs +0 -3
  145. package/templates/ts/jest.config.js +0 -8
  146. package/templates/ts/web/jest.config.js +0 -8
  147. /package/templates/{esm-js → js}/api/vitest.config.js +0 -0
  148. /package/templates/{esm-js → js}/eslint.config.js +0 -0
  149. /package/templates/{esm-js → js}/vitest.config.mjs +0 -0
  150. /package/templates/{esm-js → js}/web/vitest.setup.js +0 -0
  151. /package/templates/overlays/{cjs/yarn → yarn}/.yarnrc.yml +0 -0
  152. /package/templates/{esm-ts → ts}/api/vitest.config.ts +0 -0
  153. /package/templates/{esm-ts → ts}/vitest.config.ts +0 -0
  154. /package/templates/{esm-ts → ts}/web/vitest.setup.ts +0 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-cedar-app",
3
- "version": "6.0.2",
3
+ "version": "6.0.3-next.275",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/cedarjs/cedar.git",
@@ -20,33 +20,31 @@
20
20
  "build:watch": "nodemon --watch src --ignore dist,template --exec \"yarn build\"",
21
21
  "prepublishOnly": "NODE_ENV=production yarn build",
22
22
  "set-up-test-project": "node ./scripts/setUpTestProject.js",
23
- "test": "vitest run templates",
23
+ "test": "vitest run templates generateLockfile",
24
24
  "test:e2e": "vitest --pool=forks run e2e",
25
25
  "ts-to-js": "yarn node ./scripts/tsToJS.js"
26
26
  },
27
27
  "devDependencies": {
28
- "@babel/core": "^7.26.10",
29
- "@babel/plugin-transform-typescript": "^7.26.8",
30
- "@cedarjs/framework-tools": "6.0.2",
31
- "@cedarjs/tui": "6.0.2",
28
+ "@cedarjs/cli-helpers": "6.0.3-next.275",
29
+ "@cedarjs/framework-tools": "6.0.3-next.275",
30
+ "@cedarjs/tui": "6.0.3-next.275",
32
31
  "@opentelemetry/api": "1.9.1",
33
- "@opentelemetry/exporter-trace-otlp-http": "0.57.2",
34
- "@opentelemetry/resources": "1.30.1",
35
- "@opentelemetry/sdk-trace-node": "1.30.1",
36
- "@opentelemetry/semantic-conventions": "1.41.1",
37
- "@types/babel__core": "7.20.5",
32
+ "@opentelemetry/exporter-trace-otlp-http": "0.222.0",
33
+ "@opentelemetry/resources": "2.11.0",
34
+ "@opentelemetry/sdk-trace-node": "2.11.0",
35
+ "@opentelemetry/semantic-conventions": "1.43.0",
38
36
  "@types/klaw-sync": "6.0.5",
39
- "ansis": "4.3.1",
37
+ "ansis": "4.4.0",
40
38
  "ci-info": "4.4.0",
41
39
  "envinfo": "7.21.0",
42
40
  "execa": "5.1.1",
43
41
  "gradient-string": "3.0.0",
44
42
  "klaw-sync": "7.0.0",
45
- "semver": "7.8.5",
46
- "systeminformation": "5.33.8",
43
+ "systeminformation": "5.33.11",
47
44
  "termi-link": "1.1.0",
48
45
  "untildify": "4.0.0",
49
- "uuid": "11.1.0",
46
+ "uuid": "11.1.1",
47
+ "verkit": "0.4.0",
50
48
  "vitest": "4.1.11",
51
49
  "yargs": "17.7.3"
52
50
  },
@@ -5,7 +5,6 @@
5
5
  "target": "es2023",
6
6
  "module": "ESNext",
7
7
  "moduleResolution": "Bundler",
8
- "allowImportingTsExtensions": true,
9
8
  "skipLibCheck": false,
10
9
  "rootDirs": [
11
10
  "./src",
@@ -35,8 +34,9 @@
35
34
  },
36
35
  "include": [
37
36
  "src",
37
+ "db",
38
38
  "../.cedar/types/includes/all-*",
39
39
  "../.cedar/types/includes/api-*",
40
40
  "../types"
41
41
  ]
42
- }
42
+ }
@@ -1,13 +1,19 @@
1
1
  {
2
2
  "name": "api",
3
- "type": "commonjs",
3
+ "type": "module",
4
4
  "version": "0.0.0",
5
5
  "private": true,
6
6
  "dependencies": {
7
- "@cedarjs/api": "6.0.2",
8
- "@cedarjs/graphql-server": "6.0.2",
9
- "@prisma/adapter-better-sqlite3": "7.8.0",
10
- "@prisma/client": "7.8.0",
11
- "better-sqlite3": "12.11.1"
7
+ "@prisma/adapter-better-sqlite3": "7.10.0",
8
+ "@prisma/client": "7.10.0",
9
+ "@cedarjs/api": "6.0.3-next.275",
10
+ "@cedarjs/graphql-server": "6.0.3-next.275",
11
+ "better-sqlite3": "12.11.1",
12
+ "@cedarjs/context": "6.0.3-next.275",
13
+ "graphql-tag": "2.12.7"
14
+ },
15
+ "devDependencies": {
16
+ "@cedarjs/vite": "6.0.3-next.275",
17
+ "vitest": "4.1.11"
12
18
  }
13
19
  }
@@ -1,4 +1,4 @@
1
- import gql from 'graphql-tag'
1
+ import { gql } from 'graphql-tag'
2
2
 
3
3
  import { createValidatorDirective } from '@cedarjs/graphql-server'
4
4
 
@@ -1,4 +1,4 @@
1
- import gql from 'graphql-tag'
1
+ import { gql } from 'graphql-tag'
2
2
 
3
3
  import { createValidatorDirective } from '@cedarjs/graphql-server'
4
4
 
@@ -26,7 +26,7 @@ export const requireAuth = ({ roles }) => {
26
26
 
27
27
  export const getCurrentUser = async () => {
28
28
  throw new Error(
29
- 'Auth is not set up yet. See https://cedarjs.com/docs/authentication ' +
30
- 'to get started'
29
+ 'Auth is not set up yet. See https://cedarjs.com/docs/authentication to ' +
30
+ 'get started'
31
31
  )
32
32
  }
@@ -18,7 +18,9 @@ const resolveSqliteUrl = (url = 'file:./db/dev.db') => {
18
18
  return url
19
19
  }
20
20
 
21
- return `file:${path.resolve(getPaths().api.base, url.slice('file:'.length))}`
21
+ const apiDir = getPaths().api.base
22
+
23
+ return `file:${path.resolve(apiDir, url.slice('file:'.length))}`
22
24
  }
23
25
 
24
26
  const adapter = new PrismaBetterSqlite3({
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "private": true,
3
- "type": "commonjs",
3
+ "type": "module",
4
4
  "workspaces": [
5
5
  "api",
6
6
  "web"
@@ -13,16 +13,21 @@
13
13
  "start:web": "cedarjs-server web"
14
14
  },
15
15
  "dependencies": {
16
- "@cedarjs/api-server": "6.0.2"
16
+ "@cedarjs/api-server": "6.0.3-next.275"
17
17
  },
18
18
  "devDependencies": {
19
- "@cedarjs/core": "6.0.2",
20
- "@cedarjs/eslint-config": "6.0.2",
21
- "@cedarjs/project-config": "6.0.2",
22
- "@cedarjs/testing": "6.0.2"
19
+ "@cedarjs/core": "6.0.3-next.275",
20
+ "@cedarjs/eslint-config": "6.0.3-next.275",
21
+ "@cedarjs/project-config": "6.0.3-next.275",
22
+ "@cedarjs/testing": "6.0.3-next.275",
23
+ "vitest": "4.1.11"
23
24
  },
24
25
  "engines": {
25
26
  "node": "24.x"
26
27
  },
27
- "packageManager": "yarn@4.14.1"
28
+ "packageManager": "yarn@4.14.1",
29
+ "resolutions": {
30
+ "react-is": "19.3.0",
31
+ "vite": "7.3.6"
32
+ }
28
33
  }
@@ -5,7 +5,6 @@
5
5
  "target": "es2023",
6
6
  "module": "node20",
7
7
  "moduleResolution": "node16",
8
- "allowImportingTsExtensions": true,
9
8
  "rootDirs": [
10
9
  "../api/src",
11
10
  "../.cedar/types/mirror/api/src",
@@ -58,4 +57,4 @@
58
57
  "../.cedar/types/includes/web-*",
59
58
  "../types"
60
59
  ]
61
- }
60
+ }
@@ -5,7 +5,6 @@
5
5
  "target": "ES2022",
6
6
  "module": "ESNext",
7
7
  "moduleResolution": "Bundler",
8
- "allowImportingTsExtensions": true,
9
8
  "skipLibCheck": false,
10
9
  "rootDirs": [
11
10
  "./src",
@@ -51,4 +50,4 @@
51
50
  "../types",
52
51
  "./types"
53
52
  ]
54
- }
53
+ }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "web",
3
- "type": "commonjs",
3
+ "type": "module",
4
4
  "version": "0.0.0",
5
5
  "private": true,
6
6
  "browserslist": {
@@ -12,15 +12,19 @@
12
12
  ]
13
13
  },
14
14
  "dependencies": {
15
- "@cedarjs/forms": "6.0.2",
16
- "@cedarjs/router": "6.0.2",
17
- "@cedarjs/web": "6.0.2",
18
- "react": "18.3.1",
19
- "react-dom": "18.3.1"
15
+ "@cedarjs/forms": "6.0.3-next.275",
16
+ "@cedarjs/router": "6.0.3-next.275",
17
+ "@cedarjs/web": "6.0.3-next.275",
18
+ "react": "19.3.0",
19
+ "react-dom": "19.3.0"
20
20
  },
21
21
  "devDependencies": {
22
- "@cedarjs/vite": "6.0.2",
23
- "@types/react": "^18.2.55",
24
- "@types/react-dom": "^18.2.19"
22
+ "@cedarjs/vite": "6.0.3-next.275",
23
+ "@types/react": "^19.2.0",
24
+ "@types/react-dom": "^19.2.0",
25
+ "@cedarjs/testing": "6.0.3-next.275",
26
+ "@testing-library/jest-dom": "6.9.1",
27
+ "@testing-library/react": "16.3.3",
28
+ "vite": "7.3.6"
25
29
  }
26
30
  }
@@ -48,7 +48,6 @@ export default DevFatalErrorPage ||
48
48
  `,
49
49
  }}
50
50
  />
51
-
52
51
  <section>
53
52
  <h1>
54
53
  <span>Something went wrong</span>
@@ -35,7 +35,6 @@ export default () => (
35
35
  `,
36
36
  }}
37
37
  />
38
-
39
38
  <section>
40
39
  <h1>
41
40
  <span>404 Page Not Found</span>
@@ -1,7 +1,15 @@
1
+ /// <reference types="vitest/config" />
2
+
1
3
  import { defineConfig } from 'vite'
2
4
 
3
5
  import { cedar } from '@cedarjs/vite'
4
6
 
5
- export default defineConfig({
6
- plugins: [cedar()],
7
- })
7
+ export default defineConfig(({ mode }) => ({
8
+ plugins: [cedar({ mode })],
9
+ test: {
10
+ environment: 'jsdom',
11
+ setupFiles: ['./vitest.setup.js'],
12
+ // Enables global test APIs like describe, it, expect
13
+ globals: true,
14
+ },
15
+ }))
@@ -13,21 +13,21 @@
13
13
  "start:web": "cedarjs-server web"
14
14
  },
15
15
  "dependencies": {
16
- "@cedarjs/api-server": "6.0.2"
16
+ "@cedarjs/api-server": "6.0.3-next.275"
17
17
  },
18
18
  "devDependencies": {
19
- "@cedarjs/core": "6.0.2",
20
- "@cedarjs/eslint-config": "6.0.2",
21
- "@cedarjs/project-config": "6.0.2",
22
- "@cedarjs/testing": "6.0.2",
23
- "prisma": "7.8.0",
24
- "vitest": "4.1.10"
19
+ "prisma": "7.10.0",
20
+ "@cedarjs/core": "6.0.3-next.275",
21
+ "@cedarjs/eslint-config": "6.0.3-next.275",
22
+ "@cedarjs/project-config": "6.0.3-next.275",
23
+ "@cedarjs/testing": "6.0.3-next.275",
24
+ "vitest": "4.1.11"
25
25
  },
26
26
  "engines": {
27
27
  "node": "24.x"
28
28
  },
29
29
  "overrides": {
30
- "react-is": "19.2.3",
30
+ "react-is": "19.3.0",
31
31
  "vite": "7.3.6"
32
32
  }
33
33
  }
@@ -9,15 +9,15 @@
9
9
  "start:web": "cedarjs-server web"
10
10
  },
11
11
  "dependencies": {
12
- "@cedarjs/api-server": "6.0.2"
12
+ "@cedarjs/api-server": "6.0.3-next.275"
13
13
  },
14
14
  "devDependencies": {
15
- "@cedarjs/core": "6.0.2",
16
- "@cedarjs/eslint-config": "6.0.2",
17
- "@cedarjs/project-config": "6.0.2",
18
- "@cedarjs/testing": "6.0.2",
19
- "prisma": "7.8.0",
20
- "vitest": "4.1.10"
15
+ "prisma": "7.10.0",
16
+ "@cedarjs/core": "6.0.3-next.275",
17
+ "@cedarjs/eslint-config": "6.0.3-next.275",
18
+ "@cedarjs/project-config": "6.0.3-next.275",
19
+ "@cedarjs/testing": "6.0.3-next.275",
20
+ "vitest": "4.1.11"
21
21
  },
22
22
  "engines": {
23
23
  "node": "24.x",
@@ -20,5 +20,5 @@ allowBuilds:
20
20
  unrs-resolver: false
21
21
 
22
22
  overrides:
23
- 'react-is': '19.2.3'
23
+ 'react-is': '19.3.0'
24
24
  'vite': '7.3.6'
@@ -13,22 +13,22 @@
13
13
  "start:web": "cedarjs-server web"
14
14
  },
15
15
  "dependencies": {
16
- "@cedarjs/api-server": "6.0.2"
16
+ "@cedarjs/api-server": "6.0.3-next.275"
17
17
  },
18
18
  "devDependencies": {
19
- "@cedarjs/core": "6.0.2",
20
- "@cedarjs/eslint-config": "6.0.2",
21
- "@cedarjs/project-config": "6.0.2",
22
- "@cedarjs/testing": "6.0.2",
23
- "prisma": "7.8.0",
24
- "vitest": "4.1.10"
19
+ "prisma": "7.10.0",
20
+ "@cedarjs/core": "6.0.3-next.275",
21
+ "@cedarjs/eslint-config": "6.0.3-next.275",
22
+ "@cedarjs/project-config": "6.0.3-next.275",
23
+ "@cedarjs/testing": "6.0.3-next.275",
24
+ "vitest": "4.1.11"
25
25
  },
26
26
  "engines": {
27
27
  "node": "24.x"
28
28
  },
29
29
  "packageManager": "yarn@4.14.1",
30
30
  "resolutions": {
31
- "react-is": "19.2.3",
31
+ "react-is": "19.3.0",
32
32
  "vite": "7.3.6"
33
33
  },
34
34
  "dependenciesMeta": {
@@ -1,13 +1,19 @@
1
1
  {
2
2
  "name": "api",
3
- "type": "commonjs",
3
+ "type": "module",
4
4
  "version": "0.0.0",
5
5
  "private": true,
6
6
  "dependencies": {
7
- "@cedarjs/api": "6.0.2",
8
- "@cedarjs/graphql-server": "6.0.2",
9
- "@prisma/adapter-better-sqlite3": "7.8.0",
10
- "@prisma/client": "7.8.0",
11
- "better-sqlite3": "12.11.1"
7
+ "@prisma/adapter-better-sqlite3": "7.10.0",
8
+ "@prisma/client": "7.10.0",
9
+ "@cedarjs/api": "6.0.3-next.275",
10
+ "@cedarjs/graphql-server": "6.0.3-next.275",
11
+ "better-sqlite3": "12.11.1",
12
+ "@cedarjs/context": "6.0.3-next.275",
13
+ "graphql-tag": "2.12.7"
14
+ },
15
+ "devDependencies": {
16
+ "@cedarjs/vite": "6.0.3-next.275",
17
+ "vitest": "4.1.11"
12
18
  }
13
19
  }
@@ -1,4 +1,4 @@
1
- import gql from 'graphql-tag'
1
+ import { gql } from 'graphql-tag'
2
2
 
3
3
  import type { ValidatorDirectiveFunc } from '@cedarjs/graphql-server'
4
4
  import { createValidatorDirective } from '@cedarjs/graphql-server'
@@ -1,4 +1,4 @@
1
- import gql from 'graphql-tag'
1
+ import { gql } from 'graphql-tag'
2
2
 
3
3
  import { createValidatorDirective } from '@cedarjs/graphql-server'
4
4
 
@@ -26,7 +26,7 @@ export const requireAuth = ({ roles }) => {
26
26
 
27
27
  export const getCurrentUser = async () => {
28
28
  throw new Error(
29
- 'Auth is not set up yet. See https://cedarjs.com/docs/authentication ' +
30
- 'to get started'
29
+ 'Auth is not set up yet. See https://cedarjs.com/docs/authentication to ' +
30
+ 'get started'
31
31
  )
32
32
  }
@@ -18,7 +18,9 @@ const resolveSqliteUrl = (url = 'file:./db/dev.db') => {
18
18
  return url
19
19
  }
20
20
 
21
- return `file:${path.resolve(getPaths().api.base, url.slice('file:'.length))}`
21
+ const apiDir = getPaths().api.base
22
+
23
+ return `file:${path.resolve(apiDir, url.slice('file:'.length))}`
22
24
  }
23
25
 
24
26
  const adapter = new PrismaBetterSqlite3({
@@ -20,6 +20,7 @@
20
20
  },
21
21
  "include": [
22
22
  "src",
23
+ "db",
23
24
  "../.cedar/types/includes/all-*",
24
25
  "../.cedar/types/includes/api-*",
25
26
  "../types"
@@ -0,0 +1,11 @@
1
+ import cedarConfig from '@cedarjs/eslint-config'
2
+
3
+ export default [
4
+ ...(await cedarConfig()),
5
+ {
6
+ files: ['web/src/**/*Cell.tsx'],
7
+ rules: {
8
+ '@cedarjs/cell-type-annotations': 'error',
9
+ },
10
+ },
11
+ ]
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "private": true,
3
- "type": "commonjs",
3
+ "type": "module",
4
4
  "workspaces": [
5
5
  "api",
6
6
  "web"
@@ -13,16 +13,21 @@
13
13
  "start:web": "cedarjs-server web"
14
14
  },
15
15
  "dependencies": {
16
- "@cedarjs/api-server": "6.0.2"
16
+ "@cedarjs/api-server": "6.0.3-next.275"
17
17
  },
18
18
  "devDependencies": {
19
- "@cedarjs/core": "6.0.2",
20
- "@cedarjs/eslint-config": "6.0.2",
21
- "@cedarjs/project-config": "6.0.2",
22
- "@cedarjs/testing": "6.0.2"
19
+ "@cedarjs/core": "6.0.3-next.275",
20
+ "@cedarjs/eslint-config": "6.0.3-next.275",
21
+ "@cedarjs/project-config": "6.0.3-next.275",
22
+ "@cedarjs/testing": "6.0.3-next.275",
23
+ "vitest": "4.1.11"
23
24
  },
24
25
  "engines": {
25
26
  "node": "24.x"
26
27
  },
27
- "packageManager": "yarn@4.14.1"
28
+ "packageManager": "yarn@4.14.1",
29
+ "resolutions": {
30
+ "react-is": "19.3.0",
31
+ "vite": "7.3.6"
32
+ }
28
33
  }
@@ -6,7 +6,6 @@
6
6
  "target": "es2023",
7
7
  "module": "node20",
8
8
  "moduleResolution": "node16",
9
- "allowImportingTsExtensions": true,
10
9
  "rootDirs": [
11
10
  "../api/src",
12
11
  "../.cedar/types/mirror/api/src",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "web",
3
- "type": "commonjs",
3
+ "type": "module",
4
4
  "version": "0.0.0",
5
5
  "private": true,
6
6
  "browserslist": {
@@ -12,15 +12,19 @@
12
12
  ]
13
13
  },
14
14
  "dependencies": {
15
- "@cedarjs/forms": "6.0.2",
16
- "@cedarjs/router": "6.0.2",
17
- "@cedarjs/web": "6.0.2",
18
- "react": "18.3.1",
19
- "react-dom": "18.3.1"
15
+ "@cedarjs/forms": "6.0.3-next.275",
16
+ "@cedarjs/router": "6.0.3-next.275",
17
+ "@cedarjs/web": "6.0.3-next.275",
18
+ "react": "19.3.0",
19
+ "react-dom": "19.3.0"
20
20
  },
21
21
  "devDependencies": {
22
- "@cedarjs/vite": "6.0.2",
23
- "@types/react": "^18.2.55",
24
- "@types/react-dom": "^18.2.19"
22
+ "@cedarjs/vite": "6.0.3-next.275",
23
+ "@types/react": "^19.2.0",
24
+ "@types/react-dom": "^19.2.0",
25
+ "@cedarjs/testing": "6.0.3-next.275",
26
+ "@testing-library/jest-dom": "6.9.1",
27
+ "@testing-library/react": "16.3.3",
28
+ "vite": "7.3.6"
25
29
  }
26
30
  }
@@ -1,7 +1,15 @@
1
+ /// <reference types="vitest/config" />
2
+
1
3
  import { defineConfig } from 'vite'
2
4
 
3
5
  import { cedar } from '@cedarjs/vite'
4
6
 
5
- export default defineConfig({
6
- plugins: [cedar()],
7
- })
7
+ export default defineConfig(({ mode }) => ({
8
+ plugins: [cedar({ mode })],
9
+ test: {
10
+ environment: 'jsdom',
11
+ setupFiles: ['./vitest.setup.ts'],
12
+ // Enables global test APIs like describe, it, expect
13
+ globals: true,
14
+ },
15
+ }))
@@ -1,44 +0,0 @@
1
- # .cedar
2
-
3
- ## What is this directory?
4
-
5
- Cedar uses this `.cedar` directory to store transitory data that aids in the smooth and convenient operation of your Cedar project.
6
-
7
- ## Do I need to do anything with this directory?
8
-
9
- No. You shouldn't have to create, edit or delete anything in this directory in your day-to-day work with Cedar.
10
-
11
- You don't need to commit any other contents of this directory to your version control system. It's ignored by default.
12
-
13
- ## What's in this directory?
14
-
15
- ### Files
16
-
17
- | Name | Description |
18
- | :---------------- | :----------------------------------------------------------------------------------------------------------------- |
19
- | commandCache.json | This file contains mappings to assist the Cedar CLI in efficiently executing commands. |
20
- | schema.graphql | This is the GraphQL schema which has been automatically generated from your Cedar project. |
21
- | telemetry.txt | Contains a unique ID used for telemetry. This value is rotated every 24 hours to protect your project's anonymity. |
22
- | test.db | The sqlite database used when running tests. |
23
-
24
- ### Directories
25
-
26
- | Name | Description |
27
- | :---------- | :----------------------------------------------------------------------------------------------------------------------------------------------- |
28
- | locks | Stores temporary files that Cedar uses to keep track of the execution of async/background tasks between processes. |
29
- | logs | Stores log files for background tasks such as update checking. |
30
- | prebuild | Stores transpiled JavaScript that is generated as part of Cedar's build process. |
31
- | telemetry | Stores the recent telemetry that the Cedar CLI has generated. You may inspect these files to see everything Cedar is anonymously collecting. |
32
- | types | Stores the results of type generation. |
33
- | updateCheck | Stores a file which contains the results of checking for Cedar updates. |
34
- | studio | Used to store data for `cedar studio` |
35
-
36
- We try to keep this README up to date but you may, from time to time, find other files or directories in this `.cedar` directory that have not yet been documented here. This is likely nothing to worry about but feel free to let us know and we'll update this list.
37
-
38
- ### Telemetry
39
-
40
- CedarJS collects completely anonymous telemetry data about general usage. For transparency, that data is viewable in the respective directories and files. To learn more and manage your project's settings, visit [telemetry.redwoodjs.com](https://telemetry.redwoodjs.com).
41
-
42
- ### Have any questions?
43
-
44
- Feel free to reach out to us on the [CedarJS Discord](https://cedarjs.com/discord) if you have any questions.
@@ -1,10 +0,0 @@
1
- # editorconfig.org
2
- root = true
3
-
4
- [*]
5
- charset = utf-8
6
- end_of_line = lf
7
- indent_size = 2
8
- indent_style = space
9
- insert_final_newline = true
10
- trim_trailing_whitespace = true
@@ -1,15 +0,0 @@
1
- # THIS FILE SHOULD NOT BE CHECKED INTO YOUR VERSION CONTROL SYSTEM
2
- #
3
- # Environment variables set here will override those in .env.defaults.
4
- # Any environment variables you need in production you will need to setup with
5
- # your hosting provider. For example in Netlify you can add environment
6
- # variables in Settings > Build & Deploy > environment
7
- #
8
- # DATABASE_URL=postgres://user:pass@postgreshost.com:5432/database_name
9
- # TEST_DATABASE_URL=postgres://user:pass@postgreshost.com:5432/test_database_name
10
- #
11
- # Sets an app-specific secret used to sign and verify your own app's webhooks.
12
- # For example if you schedule a cron job with a signed payload that later will
13
- # then invoke your api-side webhook function you will use this secret to sign and the verify.
14
- # Important: Please change this default to a strong password or other secret
15
- # WEBHOOK_SECRET=THIS_IS_NOT_SECRET_PLEASE_CHANGE