@voltro/cli 0.16.0 → 0.18.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/CHANGELOG.md +297 -0
- package/bin/voltro.mjs +6 -1
- package/dist/{apiBuild-BJtiqoOu.js → apiBuild-CPDTJHkH.js} +2 -2
- package/dist/apiBuild-D1UBJ4TM.js +2 -0
- package/dist/bin.js +3 -3
- package/dist/{commands-8A5RU3MW.js → commands-laJDMj2m.js} +2679 -2444
- package/dist/dbCommand-C3R5LrBZ.js +2 -0
- package/dist/{dbCommand-OPMtO0sX.js → dbCommand-DJSxnjPt.js} +2 -2
- package/dist/{dev-DGjEvvkV.js → dev-BOFxC21E.js} +1076 -1013
- package/dist/{dev-HdG7JdSk.js → dev-DOK0w6ZW.js} +1 -1
- package/dist/{fileConventions-Cu0tM-Bl.js → fileConventions-CBNPZVOV.js} +1 -1
- package/dist/frameworkTableAssembly-DRJrAVr1.js +2 -0
- package/dist/{frameworkTableAssembly-BA2bAmYN.js → frameworkTableAssembly-sg41s14F.js} +1 -1
- package/dist/index.js +1 -1
- package/dist/{inspectMetrics-CYDSO3za.js → inspectMetrics-D1DmLeJs.js} +491 -478
- package/dist/{serveCommand-C3lq3mFd.js → serveCommand-CxcxHc9Y.js} +322 -322
- package/dist/serveEntry.js +2 -2
- package/dist/{start-BtgatJN3.js → start-Clvz4IJb.js} +379 -379
- package/dist/startEntry.js +2 -2
- package/package.json +17 -17
- package/templates/AGENTS.core.md +62 -9
- package/templates/AGENTS.md +63 -10
- package/templates/agent-docs/_index.md +1 -1
- package/templates/agent-docs/authentication.md +48 -0
- package/templates/agent-docs/cli.md +11 -7
- package/templates/agent-docs/database/migrations.md +3 -3
- package/templates/agent-docs/database/querying.md +6 -2
- package/templates/agent-docs/internationalization.md +3 -3
- package/templates/agent-docs/introduction.md +17 -3
- package/templates/agent-docs/reference.md +4 -4
- package/templates/agent-docs/routing.md +42 -40
- package/templates/agent-docs/schema-driven-ui.md +6 -3
- package/templates/agent-docs/templates/appshells.md +24 -24
- package/templates/agent-docs/whats-new.md +170 -65
- package/templates/apps/api-ai/package.json +7 -7
- package/templates/apps/api-auth/package.json +8 -8
- package/templates/apps/api-backend/package.json +7 -7
- package/templates/apps/api-backend-deactivation/package.json +7 -7
- package/templates/apps/api-backend-mail/package.json +8 -8
- package/templates/apps/api-backend-mariadb/package.json +9 -9
- package/templates/apps/api-backend-storage/package.json +8 -8
- package/templates/apps/api-data-advanced/package.json +8 -8
- package/templates/apps/api-durable/package.json +8 -8
- package/templates/apps/api-feature-flags/package.json +9 -9
- package/templates/apps/api-governance/package.json +8 -8
- package/templates/apps/api-kv/package.json +8 -8
- package/templates/apps/api-moderation/package.json +8 -8
- package/templates/apps/api-observability/package.json +8 -8
- package/templates/apps/api-ratelimit/package.json +8 -8
- package/templates/apps/api-rbac/package.json +8 -8
- package/templates/apps/api-rest/package.json +7 -7
- package/templates/apps/api-saas/package.json +11 -11
- package/templates/apps/api-search/package.json +8 -8
- package/templates/apps/api-versioning/package.json +8 -8
- package/templates/apps/api-webhooks/package.json +9 -9
- package/templates/apps/changelog/package.json +6 -6
- package/templates/apps/changelog/src/pages/[locale]/{[slug].page.tsx → [slug]/page.tsx} +4 -4
- package/templates/apps/changelog/src/pages/[locale]/mirrors.test.tsx +2 -2
- package/templates/apps/changelog/src/pages/[locale]/{index.page.tsx → page.tsx} +2 -2
- package/templates/apps/changelog/src/pages/{[slug].page.test.tsx → [slug]/page.test.tsx} +1 -1
- package/templates/apps/changelog/src/pages/{[slug].page.tsx → [slug]/page.tsx} +2 -2
- package/templates/apps/changelog/src/pages/{index.page.test.tsx → page.test.tsx} +1 -1
- package/templates/apps/edge-functions/package.json +2 -2
- package/templates/apps/frontend-admin/package.json +8 -8
- package/templates/apps/frontend-admin/src/pages/(marketing)/{login.page.test.tsx → login/page.test.tsx} +2 -2
- package/templates/apps/frontend-admin/src/pages/(marketing)/{login.page.tsx → login/page.tsx} +2 -2
- package/templates/apps/frontend-admin/src/pages/(marketing)/{index.page.test.tsx → page.test.tsx} +1 -1
- package/templates/apps/frontend-admin/src/pages/admin/{[entity].page.tsx → [entity]/page.tsx} +1 -1
- package/templates/apps/frontend-admin/src/pages/admin/entity.test.tsx +1 -1
- package/templates/apps/frontend-admin/src/pages/admin/{index.page.test.tsx → page.test.tsx} +1 -1
- package/templates/apps/frontend-app/package.json +8 -8
- package/templates/apps/frontend-app/src/pages/{index.page.test.tsx → page.test.tsx} +1 -1
- package/templates/apps/frontend-app/src/pages/{schema-ui.page.test.tsx → schema-ui/page.test.tsx} +2 -2
- package/templates/apps/frontend-app/src/pages/{schema-ui.page.tsx → schema-ui/page.tsx} +1 -1
- package/templates/apps/frontend-blank/package.json +7 -7
- package/templates/apps/frontend-blank/src/pages/{index.page.test.tsx → page.test.tsx} +1 -1
- package/templates/apps/frontend-contact/package.json +7 -7
- package/templates/apps/frontend-contact/src/pages/[locale]/{index.page.tsx → page.tsx} +2 -2
- package/templates/apps/frontend-contact/src/pages/{index.page.test.tsx → page.test.tsx} +1 -1
- package/templates/apps/frontend-dashboard/package.json +7 -7
- package/templates/apps/frontend-dashboard/src/pages/(marketing)/{login.page.test.tsx → login/page.test.tsx} +2 -2
- package/templates/apps/frontend-dashboard/src/pages/(marketing)/{login.page.tsx → login/page.tsx} +2 -2
- package/templates/apps/frontend-dashboard/src/pages/(marketing)/{index.page.test.tsx → page.test.tsx} +1 -1
- package/templates/apps/frontend-dashboard/src/pages/dashboard/{index.page.test.tsx → page.test.tsx} +1 -1
- package/templates/apps/frontend-dashboard/src/pages/dashboard/{settings.page.test.tsx → settings/page.test.tsx} +2 -2
- package/templates/apps/frontend-dashboard/src/pages/dashboard/{settings.page.tsx → settings/page.tsx} +2 -2
- package/templates/apps/frontend-docs/package.json +7 -7
- package/templates/apps/frontend-docs/src/pages/[locale]/docs/{[...slug].page.tsx → [...slug]/page.tsx} +4 -4
- package/templates/apps/frontend-docs/src/pages/[locale]/mirrors.test.tsx +2 -2
- package/templates/apps/frontend-docs/src/pages/[locale]/{index.page.tsx → page.tsx} +2 -2
- package/templates/apps/frontend-docs/src/pages/docs/{[...slug].page.test.tsx → [...slug]/page.test.tsx} +3 -3
- package/templates/apps/frontend-docs/src/pages/docs/{[...slug].page.tsx → [...slug]/page.tsx} +1 -1
- package/templates/apps/frontend-docs/src/pages/{index.page.test.tsx → page.test.tsx} +1 -1
- package/templates/apps/frontend-i18n/package.json +6 -6
- package/templates/apps/frontend-i18n/src/pages/[locale]/{about.page.tsx → about/page.tsx} +3 -3
- package/templates/apps/frontend-i18n/src/pages/[locale]/mirrors.test.tsx +2 -2
- package/templates/apps/frontend-i18n/src/pages/[locale]/{index.page.tsx → page.tsx} +2 -2
- package/templates/apps/frontend-i18n/src/pages/{about.page.test.tsx → about/page.test.tsx} +3 -3
- package/templates/apps/frontend-i18n/src/pages/{about.page.tsx → about/page.tsx} +1 -1
- package/templates/apps/frontend-i18n/src/pages/{index.page.test.tsx → page.test.tsx} +1 -1
- package/templates/apps/frontend-landing/package.json +7 -7
- package/templates/apps/frontend-landing/src/pages/[locale]/mirrors.test.tsx +1 -1
- package/templates/apps/frontend-landing/src/pages/[locale]/{index.page.tsx → page.tsx} +2 -2
- package/templates/apps/frontend-landing/src/pages/{index.page.test.tsx → page.test.tsx} +1 -1
- package/templates/apps/frontend-spa/package.json +7 -7
- package/templates/apps/frontend-spa/src/pages/{index.page.test.tsx → page.test.tsx} +1 -1
- package/templates/apps/frontend-ssr/package.json +7 -7
- package/templates/apps/frontend-ssr/src/pages/{feed.page.test.tsx → feed/page.test.tsx} +2 -2
- package/templates/apps/frontend-ssr/src/pages/{feed.page.tsx → feed/page.tsx} +1 -1
- package/templates/apps/frontend-ssr/src/pages/{feed-swr.page.test.tsx → feed-swr/page.test.tsx} +2 -2
- package/templates/apps/frontend-ssr/src/pages/{feed-swr.page.tsx → feed-swr/page.tsx} +1 -1
- package/templates/apps/frontend-ssr/src/pages/{index.page.test.tsx → page.test.tsx} +1 -1
- package/templates/apps/frontend-ssr-api/package.json +8 -8
- package/templates/apps/frontend-ssr-api/src/pages/{index.page.test.tsx → page.test.tsx} +1 -1
- package/templates/apps/frontend-static-blog/package.json +6 -6
- package/templates/apps/frontend-static-blog/src/pages/[locale]/blog/{[slug].page.tsx → [slug]/page.tsx} +4 -4
- package/templates/apps/frontend-static-blog/src/pages/[locale]/mirrors.test.tsx +2 -2
- package/templates/apps/frontend-static-blog/src/pages/[locale]/{index.page.tsx → page.tsx} +2 -2
- package/templates/apps/frontend-static-blog/src/pages/blog/{[slug].page.test.tsx → [slug]/page.test.tsx} +3 -3
- package/templates/apps/frontend-static-blog/src/pages/blog/{[slug].page.tsx → [slug]/page.tsx} +3 -3
- package/templates/apps/frontend-static-blog/src/pages/{index.page.test.tsx → page.test.tsx} +1 -1
- package/dist/apiBuild-BOczx9-m.js +0 -2
- package/dist/dbCommand-DNQ6l-su.js +0 -2
- package/dist/frameworkTableAssembly-D1zJSgOU.js +0 -2
- /package/templates/apps/changelog/src/pages/{index.page.tsx → page.tsx} +0 -0
- /package/templates/apps/frontend-admin/src/pages/(marketing)/{index.page.tsx → page.tsx} +0 -0
- /package/templates/apps/frontend-admin/src/pages/admin/{index.page.tsx → page.tsx} +0 -0
- /package/templates/apps/frontend-app/src/pages/{index.page.tsx → page.tsx} +0 -0
- /package/templates/apps/frontend-blank/src/pages/{index.page.tsx → page.tsx} +0 -0
- /package/templates/apps/frontend-contact/src/pages/{index.page.tsx → page.tsx} +0 -0
- /package/templates/apps/frontend-dashboard/src/pages/(marketing)/{index.page.tsx → page.tsx} +0 -0
- /package/templates/apps/frontend-dashboard/src/pages/dashboard/{index.page.tsx → page.tsx} +0 -0
- /package/templates/apps/frontend-docs/src/pages/{index.page.tsx → page.tsx} +0 -0
- /package/templates/apps/frontend-i18n/src/pages/{index.page.tsx → page.tsx} +0 -0
- /package/templates/apps/frontend-landing/src/pages/{index.page.tsx → page.tsx} +0 -0
- /package/templates/apps/frontend-spa/src/pages/{index.page.tsx → page.tsx} +0 -0
- /package/templates/apps/frontend-ssr/src/pages/{index.page.tsx → page.tsx} +0 -0
- /package/templates/apps/frontend-ssr-api/src/pages/{index.page.tsx → page.tsx} +0 -0
- /package/templates/apps/frontend-static-blog/src/pages/{index.page.tsx → page.tsx} +0 -0
package/templates/apps/frontend-ssr/src/pages/{feed-swr.page.test.tsx → feed-swr/page.test.tsx}
RENAMED
|
@@ -7,13 +7,13 @@ import { afterEach, beforeEach, describe, expect, test, vi } from 'vitest'
|
|
|
7
7
|
import { act, createElement, type ReactNode } from 'react'
|
|
8
8
|
import { createRoot, type Root } from 'react-dom/client'
|
|
9
9
|
import { I18nProvider } from '@voltro/i18n'
|
|
10
|
-
import enCatalog from '
|
|
10
|
+
import enCatalog from '../../locales/en'
|
|
11
11
|
|
|
12
12
|
const loaderData = vi.fn<() => unknown>()
|
|
13
13
|
vi.mock('@voltro/web', () => ({ useLoaderData: () => loaderData() }))
|
|
14
14
|
|
|
15
15
|
const { default: FeedSwr, meta, loader, renderMode, revalidate, staleWhileRevalidate } =
|
|
16
|
-
await import('./
|
|
16
|
+
await import('./page')
|
|
17
17
|
|
|
18
18
|
;(globalThis as { IS_REACT_ACT_ENVIRONMENT?: boolean }).IS_REACT_ACT_ENVIRONMENT = true
|
|
19
19
|
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
import type { ReactNode } from 'react'
|
|
7
7
|
import { useLoaderData, type LoaderFn, type PageMeta } from '@voltro/web'
|
|
8
8
|
import { T } from '@voltro/i18n'
|
|
9
|
-
import { getCatalog } from '
|
|
9
|
+
import { getCatalog } from '../../locales/index'
|
|
10
10
|
|
|
11
11
|
export const renderMode = 'isr' as const
|
|
12
12
|
export const revalidate = '5 seconds'
|
|
@@ -18,7 +18,7 @@ vi.mock('@voltro/web', () => ({
|
|
|
18
18
|
useServerRequest: () => serverRequest(),
|
|
19
19
|
}))
|
|
20
20
|
|
|
21
|
-
const { default: Home, meta, loader, renderMode } = await import('./
|
|
21
|
+
const { default: Home, meta, loader, renderMode } = await import('./page')
|
|
22
22
|
|
|
23
23
|
;(globalThis as { IS_REACT_ACT_ENVIRONMENT?: boolean }).IS_REACT_ACT_ENVIRONMENT = true
|
|
24
24
|
|
|
@@ -11,18 +11,18 @@
|
|
|
11
11
|
"test": "voltro test"
|
|
12
12
|
},
|
|
13
13
|
"dependencies": {
|
|
14
|
-
"@{{projectName}}/api": "0.
|
|
15
|
-
"@voltro/cli": "0.
|
|
16
|
-
"@voltro/client": "0.
|
|
17
|
-
"@voltro/env": "0.
|
|
18
|
-
"@voltro/i18n": "0.
|
|
19
|
-
"@voltro/ui-shadcn": "0.
|
|
20
|
-
"@voltro/web": "0.
|
|
14
|
+
"@{{projectName}}/api": "0.18.0",
|
|
15
|
+
"@voltro/cli": "0.18.0",
|
|
16
|
+
"@voltro/client": "0.18.0",
|
|
17
|
+
"@voltro/env": "0.18.0",
|
|
18
|
+
"@voltro/i18n": "0.18.0",
|
|
19
|
+
"@voltro/ui-shadcn": "0.18.0",
|
|
20
|
+
"@voltro/web": "0.18.0",
|
|
21
21
|
"react": "^19.0.0",
|
|
22
22
|
"react-dom": "^19.0.0"
|
|
23
23
|
},
|
|
24
24
|
"devDependencies": {
|
|
25
|
-
"@voltro/devtools": "0.
|
|
25
|
+
"@voltro/devtools": "0.18.0",
|
|
26
26
|
"@types/react": "^19.0.0",
|
|
27
27
|
"@types/react-dom": "^19.0.0",
|
|
28
28
|
"typescript": "^5.7.0",
|
|
@@ -17,7 +17,7 @@ const useSubscription = vi.fn<() => { data: unknown }>()
|
|
|
17
17
|
vi.mock('@voltro/web', () => ({ useLoaderData: () => loaderData() }))
|
|
18
18
|
vi.mock('@voltro/client', () => ({ useSubscription: () => useSubscription() }))
|
|
19
19
|
|
|
20
|
-
const { default: Home, meta, loader, renderMode } = await import('./
|
|
20
|
+
const { default: Home, meta, loader, renderMode } = await import('./page')
|
|
21
21
|
|
|
22
22
|
;(globalThis as { IS_REACT_ACT_ENVIRONMENT?: boolean }).IS_REACT_ACT_ENVIRONMENT = true
|
|
23
23
|
|
|
@@ -11,16 +11,16 @@
|
|
|
11
11
|
"test": "voltro test"
|
|
12
12
|
},
|
|
13
13
|
"dependencies": {
|
|
14
|
-
"@voltro/cli": "0.
|
|
15
|
-
"@voltro/client": "0.
|
|
16
|
-
"@voltro/env": "0.
|
|
17
|
-
"@voltro/i18n": "0.
|
|
18
|
-
"@voltro/web": "0.
|
|
14
|
+
"@voltro/cli": "0.18.0",
|
|
15
|
+
"@voltro/client": "0.18.0",
|
|
16
|
+
"@voltro/env": "0.18.0",
|
|
17
|
+
"@voltro/i18n": "0.18.0",
|
|
18
|
+
"@voltro/web": "0.18.0",
|
|
19
19
|
"react": "^19.0.0",
|
|
20
20
|
"react-dom": "^19.0.0"
|
|
21
21
|
},
|
|
22
22
|
"devDependencies": {
|
|
23
|
-
"@voltro/devtools": "0.
|
|
23
|
+
"@voltro/devtools": "0.18.0",
|
|
24
24
|
"@types/react": "^19.0.0",
|
|
25
25
|
"@types/react-dom": "^19.0.0",
|
|
26
26
|
"typescript": "^5.7.0",
|
|
@@ -6,11 +6,11 @@
|
|
|
6
6
|
// slug (the bare page enumerates just the slugs; here each slug is emitted
|
|
7
7
|
// once per non-default locale). `voltro build` produces one HTML file per
|
|
8
8
|
// pair, e.g. /de/blog/hello-static.
|
|
9
|
-
import { SUPPORTED_LOCALES, DEFAULT_LOCALE } from '
|
|
10
|
-
import { posts } from '
|
|
9
|
+
import { SUPPORTED_LOCALES, DEFAULT_LOCALE } from '../../../../lib/locale'
|
|
10
|
+
import { posts } from '../../../../content/posts'
|
|
11
11
|
|
|
12
|
-
export { default } from '
|
|
13
|
-
export { renderMode, interactive, loader, meta } from '
|
|
12
|
+
export { default } from '../../../blog/[slug]/page'
|
|
13
|
+
export { renderMode, interactive, loader, meta } from '../../../blog/[slug]/page'
|
|
14
14
|
|
|
15
15
|
export const getStaticPaths = async (): Promise<
|
|
16
16
|
Array<{ params: { locale: string; slug: string } }>
|
|
@@ -32,8 +32,8 @@ vi.mock('@voltro/i18n', () => ({
|
|
|
32
32
|
T: ({ id }: { id: string }) => id,
|
|
33
33
|
}))
|
|
34
34
|
|
|
35
|
-
const indexMirror = await import('./
|
|
36
|
-
const postMirror = await import('./blog/[slug]
|
|
35
|
+
const indexMirror = await import('./page')
|
|
36
|
+
const postMirror = await import('./blog/[slug]/page')
|
|
37
37
|
|
|
38
38
|
describe('home mirror — getStaticPaths', () => {
|
|
39
39
|
test('emits only non-default locales (just /de)', async () => {
|
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
// The default locale is NOT listed here — it lives at the bare `/`.
|
|
5
5
|
import { SUPPORTED_LOCALES, DEFAULT_LOCALE } from '../../lib/locale'
|
|
6
6
|
|
|
7
|
-
export { default } from '../
|
|
8
|
-
export { renderMode, interactive, meta } from '../
|
|
7
|
+
export { default } from '../page'
|
|
8
|
+
export { renderMode, interactive, meta } from '../page'
|
|
9
9
|
|
|
10
10
|
export const getStaticPaths = async (): Promise<Array<{ params: { locale: string } }>> =>
|
|
11
11
|
SUPPORTED_LOCALES
|
|
@@ -10,8 +10,8 @@
|
|
|
10
10
|
import { afterEach, beforeEach, describe, expect, test, vi } from 'vitest'
|
|
11
11
|
import { act, createElement, type ComponentType, type ReactNode } from 'react'
|
|
12
12
|
import { createRoot, type Root } from 'react-dom/client'
|
|
13
|
-
import { posts, type Post } from '
|
|
14
|
-
import en from '
|
|
13
|
+
import { posts, type Post } from '../../../content/posts'
|
|
14
|
+
import en from '../../../locales/en'
|
|
15
15
|
|
|
16
16
|
const loaderData = vi.fn<() => Post>()
|
|
17
17
|
|
|
@@ -47,7 +47,7 @@ vi.mock('@voltro/i18n', () => ({
|
|
|
47
47
|
fill((en as Record<string, string>)[id] ?? id, values),
|
|
48
48
|
}))
|
|
49
49
|
|
|
50
|
-
const { default: BlogPost, getStaticPaths, loader, meta } = await import('./
|
|
50
|
+
const { default: BlogPost, getStaticPaths, loader, meta } = await import('./page')
|
|
51
51
|
|
|
52
52
|
;(globalThis as { IS_REACT_ACT_ENVIRONMENT?: boolean }).IS_REACT_ACT_ENVIRONMENT = true
|
|
53
53
|
|
package/templates/apps/frontend-static-blog/src/pages/blog/{[slug].page.tsx → [slug]/page.tsx}
RENAMED
|
@@ -12,9 +12,9 @@
|
|
|
12
12
|
import type { ReactNode } from 'react'
|
|
13
13
|
import { useLoaderData, notFound, type LoaderFn, type PageMeta } from '@voltro/web'
|
|
14
14
|
import { T, useLocale } from '@voltro/i18n'
|
|
15
|
-
import { posts, type Post } from '
|
|
16
|
-
import { withLocalePrefix } from '
|
|
17
|
-
import ReadingProgress from '
|
|
15
|
+
import { posts, type Post } from '../../../content/posts'
|
|
16
|
+
import { withLocalePrefix } from '../../../lib/locale'
|
|
17
|
+
import ReadingProgress from '../../../components/ReadingProgress.island'
|
|
18
18
|
|
|
19
19
|
export const renderMode = 'static' as const
|
|
20
20
|
export const interactive = 'islands' as const
|
|
@@ -38,7 +38,7 @@ vi.mock('@voltro/i18n', () => ({
|
|
|
38
38
|
fill(catalogs[currentLocale]?.[id] ?? id, values),
|
|
39
39
|
}))
|
|
40
40
|
|
|
41
|
-
const { default: Index, meta, renderMode, interactive } = await import('./
|
|
41
|
+
const { default: Index, meta, renderMode, interactive } = await import('./page')
|
|
42
42
|
|
|
43
43
|
;(globalThis as { IS_REACT_ACT_ENVIRONMENT?: boolean }).IS_REACT_ACT_ENVIRONMENT = true
|
|
44
44
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/templates/apps/frontend-dashboard/src/pages/(marketing)/{index.page.tsx → page.tsx}
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|