create-guren-app 1.18.4 → 1.19.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-guren-app",
3
- "version": "1.18.4",
3
+ "version": "1.19.0",
4
4
  "description": "Scaffold a Guren app: a Bun-first fullstack TypeScript framework with Laravel-style conventions, Inertia.js + React, Drizzle ORM, and an agent harness for Claude Code and other coding agents.",
5
5
  "keywords": [
6
6
  "guren",
@@ -10,7 +10,10 @@ jobs:
10
10
  checks:
11
11
  runs-on: ubuntu-latest
12
12
  steps:
13
- - uses: actions/checkout@v4
13
+ - uses: actions/checkout@v7
14
+ with:
15
+ # `guren check` judges the migrations not on main yet, which needs main's history.
16
+ fetch-depth: 0
14
17
 
15
18
  - uses: oven-sh/setup-bun@v2
16
19
 
@@ -21,13 +21,13 @@
21
21
  "test": "bun test"
22
22
  },
23
23
  "dependencies": {
24
- "@guren/cli": "^2.31.1",
25
- "@guren/core": "^1.24.0",
26
- "@guren/orm": "^2.14.0",
24
+ "@guren/cli": "^2.32.0",
25
+ "@guren/core": "^1.25.0",
26
+ "@guren/orm": "^2.15.0",
27
27
  "drizzle-orm": "1.0.0-rc.4"
28
28
  },
29
29
  "devDependencies": {
30
- "@guren/testing": "^1.14.1",
30
+ "@guren/testing": "^1.14.2",
31
31
  "bun-types": "^1.3.1",
32
32
  "drizzle-kit": "1.0.0-rc.4",
33
33
  "oxlint": "~1.81.0",
@@ -1,4 +1,5 @@
1
1
  import { Head, useForm } from '@inertiajs/react'
2
+ import { useId } from 'react'
2
3
  import type { ApiRoutes } from '@/.guren/api-client.gen'
3
4
  import { route } from '@/.guren/routes.gen'
4
5
  import Layout from '../../components/Layout.js'
@@ -19,6 +20,10 @@ export default function EditPost({ post }: Props) {
19
20
  body: post.body,
20
21
  })
21
22
 
23
+ const titleId = useId()
24
+ const excerptId = useId()
25
+ const bodyId = useId()
26
+
22
27
  return (
23
28
  <Layout>
24
29
  <Head title={`Edit ${post.title}`} />
@@ -36,8 +41,11 @@ export default function EditPost({ post }: Props) {
36
41
  }}
37
42
  >
38
43
  <div>
39
- <label className="block text-sm font-bold text-g-heading">Title</label>
44
+ <label htmlFor={titleId} className="block text-sm font-bold text-g-heading">
45
+ Title
46
+ </label>
40
47
  <input
48
+ id={titleId}
41
49
  type="text"
42
50
  value={form.data.title}
43
51
  onChange={(event) => form.setData('title', event.target.value)}
@@ -47,8 +55,11 @@ export default function EditPost({ post }: Props) {
47
55
  </div>
48
56
 
49
57
  <div>
50
- <label className="block text-sm font-bold text-g-heading">Excerpt</label>
58
+ <label htmlFor={excerptId} className="block text-sm font-bold text-g-heading">
59
+ Excerpt
60
+ </label>
51
61
  <input
62
+ id={excerptId}
52
63
  type="text"
53
64
  value={form.data.excerpt}
54
65
  onChange={(event) => form.setData('excerpt', event.target.value)}
@@ -58,8 +69,11 @@ export default function EditPost({ post }: Props) {
58
69
  </div>
59
70
 
60
71
  <div>
61
- <label className="block text-sm font-bold text-g-heading">Body</label>
72
+ <label htmlFor={bodyId} className="block text-sm font-bold text-g-heading">
73
+ Body
74
+ </label>
62
75
  <textarea
76
+ id={bodyId}
63
77
  rows={10}
64
78
  value={form.data.body}
65
79
  onChange={(event) => form.setData('body', event.target.value)}
@@ -1,4 +1,5 @@
1
1
  import { Head, useForm } from '@inertiajs/react'
2
+ import { useId } from 'react'
2
3
  import type { ApiRoutes } from '@/.guren/api-client.gen'
3
4
  import { route } from '@/.guren/routes.gen'
4
5
  import Layout from '../../components/Layout.js'
@@ -11,6 +12,10 @@ const fieldClass =
11
12
  export default function NewPost() {
12
13
  const form = useForm<PostFormData>({ title: '', excerpt: '', body: '' })
13
14
 
15
+ const titleId = useId()
16
+ const excerptId = useId()
17
+ const bodyId = useId()
18
+
14
19
  return (
15
20
  <Layout>
16
21
  <Head title="New post" />
@@ -28,8 +33,11 @@ export default function NewPost() {
28
33
  }}
29
34
  >
30
35
  <div>
31
- <label className="block text-sm font-bold text-g-heading">Title</label>
36
+ <label htmlFor={titleId} className="block text-sm font-bold text-g-heading">
37
+ Title
38
+ </label>
32
39
  <input
40
+ id={titleId}
33
41
  type="text"
34
42
  value={form.data.title}
35
43
  onChange={(event) => form.setData('title', event.target.value)}
@@ -39,8 +47,11 @@ export default function NewPost() {
39
47
  </div>
40
48
 
41
49
  <div>
42
- <label className="block text-sm font-bold text-g-heading">Excerpt</label>
50
+ <label htmlFor={excerptId} className="block text-sm font-bold text-g-heading">
51
+ Excerpt
52
+ </label>
43
53
  <input
54
+ id={excerptId}
44
55
  type="text"
45
56
  value={form.data.excerpt}
46
57
  onChange={(event) => form.setData('excerpt', event.target.value)}
@@ -50,8 +61,11 @@ export default function NewPost() {
50
61
  </div>
51
62
 
52
63
  <div>
53
- <label className="block text-sm font-bold text-g-heading">Body</label>
64
+ <label htmlFor={bodyId} className="block text-sm font-bold text-g-heading">
65
+ Body
66
+ </label>
54
67
  <textarea
68
+ id={bodyId}
55
69
  rows={10}
56
70
  value={form.data.body}
57
71
  onChange={(event) => form.setData('body', event.target.value)}
@@ -1,5 +1,5 @@
1
1
  import { Head, useForm } from '@inertiajs/react'
2
- import type { FormEvent } from 'react'
2
+ import { useId, type FormEvent } from 'react'
3
3
  import Layout from '../../components/Layout.js'
4
4
  import type { ValidationErrors } from '@guren/core'
5
5
 
@@ -22,6 +22,10 @@ export default function ProfileEdit({ profile, status }: Props) {
22
22
  password: '',
23
23
  })
24
24
 
25
+ const nameId = useId()
26
+ const emailId = useId()
27
+ const passwordId = useId()
28
+
25
29
  const handleSubmit = (event: FormEvent<HTMLFormElement>) => {
26
30
  event.preventDefault()
27
31
  form.put('/profile')
@@ -48,8 +52,11 @@ export default function ProfileEdit({ profile, status }: Props) {
48
52
 
49
53
  <form className="space-y-4" onSubmit={handleSubmit}>
50
54
  <div>
51
- <label className="block text-sm font-bold text-g-heading">Name</label>
55
+ <label htmlFor={nameId} className="block text-sm font-bold text-g-heading">
56
+ Name
57
+ </label>
52
58
  <input
59
+ id={nameId}
53
60
  type="text"
54
61
  value={form.data.name}
55
62
  onChange={(event) => form.setData('name', event.target.value)}
@@ -59,8 +66,11 @@ export default function ProfileEdit({ profile, status }: Props) {
59
66
  </div>
60
67
 
61
68
  <div>
62
- <label className="block text-sm font-bold text-g-heading">Email</label>
69
+ <label htmlFor={emailId} className="block text-sm font-bold text-g-heading">
70
+ Email
71
+ </label>
63
72
  <input
73
+ id={emailId}
64
74
  type="email"
65
75
  value={form.data.email}
66
76
  onChange={(event) => form.setData('email', event.target.value)}
@@ -70,8 +80,11 @@ export default function ProfileEdit({ profile, status }: Props) {
70
80
  </div>
71
81
 
72
82
  <div>
73
- <label className="block text-sm font-bold text-g-heading">New password</label>
83
+ <label htmlFor={passwordId} className="block text-sm font-bold text-g-heading">
84
+ New password
85
+ </label>
74
86
  <input
87
+ id={passwordId}
75
88
  type="password"
76
89
  value={form.data.password}
77
90
  onChange={(event) => form.setData('password', event.target.value)}
@@ -3,6 +3,9 @@ import env from './env.js'
3
3
 
4
4
  const database = createMySqlDatabase({
5
5
  migrationsFolder: new URL('../db/migrations', import.meta.url),
6
+ // A pending migration that drops, narrows or renames is refused at boot and by
7
+ // `guren db:migrate` until its first line reads `-- guren:allow-destructive: <reason>`.
8
+ destructiveMigrations: 'refuse',
6
9
  seedersFolder: new URL('../db/seeders', import.meta.url),
7
10
  // `context` is the application's validated environment. `guren db:*` runs this
8
11
  // outside one, where report mode reads the schema without requiring the keys
@@ -3,6 +3,9 @@ import env from './env.js'
3
3
 
4
4
  const database = createPostgresDatabase({
5
5
  migrationsFolder: new URL('../db/migrations', import.meta.url),
6
+ // A pending migration that drops, narrows or renames is refused at boot and by
7
+ // `guren db:migrate` until its first line reads `-- guren:allow-destructive: <reason>`.
8
+ destructiveMigrations: 'refuse',
6
9
  seedersFolder: new URL('../db/seeders', import.meta.url),
7
10
  // `context` is the application's validated environment. `guren db:*` runs this
8
11
  // outside one, where report mode reads the schema without requiring the keys
@@ -3,6 +3,9 @@ import env from './env.js'
3
3
 
4
4
  const database = createSqliteDatabase({
5
5
  migrationsFolder: new URL('../db/migrations', import.meta.url),
6
+ // A pending migration that drops, narrows or renames is refused at boot and by
7
+ // `guren db:migrate` until its first line reads `-- guren:allow-destructive: <reason>`.
8
+ destructiveMigrations: 'refuse',
6
9
  seedersFolder: new URL('../db/seeders', import.meta.url),
7
10
  // `context` is the application's validated environment. `guren db:*` runs this
8
11
  // outside one, where report mode reads the schema without requiring the keys
@@ -10,7 +10,10 @@ jobs:
10
10
  checks:
11
11
  runs-on: ubuntu-latest
12
12
  steps:
13
- - uses: actions/checkout@v4
13
+ - uses: actions/checkout@v7
14
+ with:
15
+ # `guren check` judges the migrations not on main yet, which needs main's history.
16
+ fetch-depth: 0
14
17
 
15
18
  - uses: oven-sh/setup-bun@v2
16
19
 
@@ -22,10 +22,10 @@
22
22
  "db:seed": "bunx guren db:seed"
23
23
  },
24
24
  "dependencies": {
25
- "@guren/cli": "^2.31.1",
26
- "@guren/core": "^1.24.0",
25
+ "@guren/cli": "^2.32.0",
26
+ "@guren/core": "^1.25.0",
27
27
  "@guren/inertia-client": "^1.2.2",
28
- "@guren/orm": "^2.14.0",
28
+ "@guren/orm": "^2.15.0",
29
29
  "@inertiajs/react": "^3.6.1",
30
30
  "drizzle-orm": "1.0.0-rc.4",
31
31
  "react": "^19.0.0",
@@ -33,7 +33,7 @@
33
33
  "zod": "^4.5.0"
34
34
  },
35
35
  "devDependencies": {
36
- "@guren/testing": "^1.14.1",
36
+ "@guren/testing": "^1.14.2",
37
37
  "@tailwindcss/vite": "^4.2.2",
38
38
  "@types/react": "^19.0.0",
39
39
  "@types/react-dom": "^19.0.0",