create-velox-app 0.6.66 → 0.6.68

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/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # create-velox-app
2
2
 
3
+ ## 0.6.68
4
+
5
+ ### Patch Changes
6
+
7
+ - ci: add Claude code review and security review workflows, add GitHub release workflow, remove npm publish job
8
+
9
+ ## 0.6.67
10
+
11
+ ### Patch Changes
12
+
13
+ - fix(create): add browser-safe routes.ts for auth template, prevent set -e from hiding CLI errors in smoke tests, add tsx to scaffolded project devDependencies
14
+
3
15
  ## 0.6.66
4
16
 
5
17
  ### Patch Changes
@@ -50,6 +50,9 @@ function generateIndexTs() {
50
50
  function generateRouterTs() {
51
51
  return compileTemplate('api/router.auth.ts', AUTH_CONFIG);
52
52
  }
53
+ function generateRoutesTs() {
54
+ return compileTemplate('api/routes.auth.ts', AUTH_CONFIG);
55
+ }
53
56
  function generateConfigDatabase(config) {
54
57
  return compileTemplate('api/config/database.ts', config);
55
58
  }
@@ -90,6 +93,7 @@ export function generateAuthTemplate(config) {
90
93
  { path: 'apps/api/prisma/schema.prisma', content: generatePrismaSchema(config) },
91
94
  // API Source files
92
95
  { path: 'apps/api/src/router.ts', content: generateRouterTs() },
96
+ { path: 'apps/api/src/routes.ts', content: generateRoutesTs() },
93
97
  { path: 'apps/api/src/index.ts', content: generateIndexTs() },
94
98
  { path: 'apps/api/src/config/app.ts', content: generateConfigApp(config) },
95
99
  { path: 'apps/api/src/config/auth.ts', content: generateAuthConfig() },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-velox-app",
3
- "version": "0.6.66",
3
+ "version": "0.6.68",
4
4
  "description": "Project scaffolder for VeloxTS framework",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -33,6 +33,7 @@
33
33
  "hot-hook": "0.4.0",
34
34
  "prisma": "7.2.0",
35
35
  "tsup": "8.5.1",
36
+ "tsx": "4.21.0",
36
37
  "typescript": "5.9.3"
37
38
  },
38
39
  "hotHook": {
@@ -31,6 +31,7 @@
31
31
  "hot-hook": "0.4.0",
32
32
  "prisma": "7.2.0",
33
33
  "tsup": "8.5.1",
34
+ "tsx": "4.21.0",
34
35
  "typescript": "5.9.3"
35
36
  },
36
37
  "hotHook": {
@@ -0,0 +1,37 @@
1
+ /**
2
+ * Browser-Safe Route Definitions
3
+ *
4
+ * This file exports route metadata that can be safely imported by frontend code.
5
+ * It does NOT import any server-side modules like procedures or database clients.
6
+ *
7
+ * IMPORTANT: Keep this file browser-safe - no Node.js imports or side effects.
8
+ */
9
+
10
+ import type { RouteMap } from '@veloxts/router';
11
+
12
+ /**
13
+ * Route mappings for the VeloxTS client
14
+ *
15
+ * Maps namespace -> procedure -> { method, path, kind }
16
+ * These must match the actual procedure definitions in ./procedures/
17
+ */
18
+ export const routes: RouteMap = {
19
+ health: {
20
+ getHealth: { method: 'GET', path: '/health', kind: 'query' },
21
+ },
22
+ auth: {
23
+ createAccount: { method: 'POST', path: '/auth/register', kind: 'mutation' },
24
+ createSession: { method: 'POST', path: '/auth/login', kind: 'mutation' },
25
+ createRefresh: { method: 'POST', path: '/auth/refresh', kind: 'mutation' },
26
+ deleteSession: { method: 'DELETE', path: '/auth/session', kind: 'mutation' },
27
+ getMe: { method: 'GET', path: '/auth/me', kind: 'query' },
28
+ },
29
+ users: {
30
+ listUsers: { method: 'GET', path: '/users', kind: 'query' },
31
+ getUser: { method: 'GET', path: '/users/:id', kind: 'query' },
32
+ createUser: { method: 'POST', path: '/users', kind: 'mutation' },
33
+ updateUser: { method: 'PUT', path: '/users/:id', kind: 'mutation' },
34
+ patchUser: { method: 'PATCH', path: '/users/:id', kind: 'mutation' },
35
+ deleteUser: { method: 'DELETE', path: '/users/:id', kind: 'mutation' },
36
+ },
37
+ };
@@ -9,7 +9,7 @@ import './styles/global.css';
9
9
  // Import router type (type-only import is erased at compile time)
10
10
  import type { AppRouter } from '../../api/src/router.js';
11
11
  /* @if auth */
12
- // Import routes from browser-safe routes file
12
+ // Import routes from browser-safe routes file (no server-side code)
13
13
  import { routes } from '../../api/src/routes.js';
14
14
 
15
15
  /* @endif auth */