@quickback-dev/cli 0.10.16 → 0.10.20
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/dist/commands/compile.d.ts.map +1 -1
- package/dist/commands/compile.js +40 -2
- package/dist/commands/compile.js.map +1 -1
- package/dist/docs/content.js +6 -6
- package/dist/docs/content.js.map +1 -1
- package/dist/index.js +1 -1
- package/dist/skill/SKILL.md +142 -1051
- package/dist/skill/agents/quickback-specialist/AGENT.md +36 -0
- package/dist/skill/docs/changelog.md +1192 -0
- package/dist/skill/docs/compiler/claude-code-skill.md +312 -0
- package/dist/skill/docs/compiler/cloud-compiler/authentication.md +63 -0
- package/dist/skill/docs/compiler/cloud-compiler/cli.md +307 -0
- package/dist/skill/docs/compiler/cloud-compiler/endpoints.md +78 -0
- package/dist/skill/docs/compiler/cloud-compiler/index.md +65 -0
- package/dist/skill/docs/compiler/cloud-compiler/local-compiler.md +115 -0
- package/dist/skill/docs/compiler/cloud-compiler/troubleshooting.md +76 -0
- package/dist/skill/docs/compiler/config/agents.md +144 -0
- package/dist/skill/docs/compiler/config/auth.md +109 -0
- package/dist/skill/docs/compiler/config/bindings.md +176 -0
- package/dist/skill/docs/compiler/config/domains.md +149 -0
- package/dist/skill/docs/compiler/config/index.md +419 -0
- package/dist/skill/docs/compiler/config/output.md +338 -0
- package/dist/skill/docs/compiler/config/providers.md +248 -0
- package/dist/skill/docs/compiler/config/security.md +255 -0
- package/dist/skill/docs/compiler/config/single-tenant.md +128 -0
- package/dist/skill/docs/compiler/config/variables.md +157 -0
- package/dist/skill/docs/compiler/definitions/access.md +445 -0
- package/dist/skill/docs/compiler/definitions/actions.md +884 -0
- package/dist/skill/docs/compiler/definitions/concepts.md +52 -0
- package/dist/skill/docs/compiler/definitions/feature.md +164 -0
- package/dist/skill/docs/compiler/definitions/firewall.md +285 -0
- package/dist/skill/docs/compiler/definitions/guards.md +241 -0
- package/dist/skill/docs/compiler/definitions/index.md +219 -0
- package/dist/skill/docs/compiler/definitions/masking.md +241 -0
- package/dist/skill/docs/compiler/definitions/read.md +220 -0
- package/dist/skill/docs/compiler/definitions/schema.md +697 -0
- package/dist/skill/docs/compiler/definitions/validation.md +35 -0
- package/dist/skill/docs/compiler/definitions/views.md +292 -0
- package/dist/skill/docs/compiler/getting-started/claude-code.md +126 -0
- package/dist/skill/docs/compiler/getting-started/full-example.md +431 -0
- package/dist/skill/docs/compiler/getting-started/hand-crafted.md +178 -0
- package/dist/skill/docs/compiler/getting-started/index.md +192 -0
- package/dist/skill/docs/compiler/getting-started/patterns.md +225 -0
- package/dist/skill/docs/compiler/getting-started/template-blog.md +280 -0
- package/dist/skill/docs/compiler/getting-started/template-cloudflare.md +260 -0
- package/dist/skill/docs/compiler/getting-started/template-empty.md +112 -0
- package/dist/skill/docs/compiler/getting-started/templates.md +111 -0
- package/dist/skill/docs/compiler/index.md +85 -0
- package/dist/skill/docs/compiler/targets/hono-api/cloudflare.md +94 -0
- package/dist/skill/docs/compiler/targets/hono-api/database/d1.md +246 -0
- package/dist/skill/docs/compiler/targets/hono-api/database/index.md +16 -0
- package/dist/skill/docs/compiler/targets/hono-api/database/neon.md +144 -0
- package/dist/skill/docs/compiler/targets/hono-api/database/using-d1.md +39 -0
- package/dist/skill/docs/compiler/targets/hono-api/index.md +37 -0
- package/dist/skill/docs/compiler/targets/hono-api/using-the-api/actions-api.md +323 -0
- package/dist/skill/docs/compiler/targets/hono-api/using-the-api/batch-operations.md +357 -0
- package/dist/skill/docs/compiler/targets/hono-api/using-the-api/caching.md +105 -0
- package/dist/skill/docs/compiler/targets/hono-api/using-the-api/crud.md +652 -0
- package/dist/skill/docs/compiler/targets/hono-api/using-the-api/errors.md +224 -0
- package/dist/skill/docs/compiler/targets/hono-api/using-the-api/index.md +37 -0
- package/dist/skill/docs/compiler/targets/hono-api/using-the-api/openapi.md +203 -0
- package/dist/skill/docs/compiler/targets/hono-api/using-the-api/query-params.md +199 -0
- package/dist/skill/docs/compiler/targets/hono-api/using-the-api/views-api.md +161 -0
- package/dist/skill/docs/compiler/targets/index.md +47 -0
- package/dist/skill/docs/compiler/targets/supabase-rls/index.md +55 -0
- package/dist/skill/docs/compiler/targets/supabase-rls/limitations.md +48 -0
- package/dist/skill/docs/compiler/targets/supabase-rls/mappings.md +99 -0
- package/dist/skill/docs/compiler/targets/supabase-rls/setup.md +88 -0
- package/dist/skill/docs/compiler/troubleshooting.md +120 -0
- package/dist/skill/docs/index.md +77 -0
- package/dist/skill/docs/stack/account-ui/customization.md +378 -0
- package/dist/skill/docs/stack/account-ui/environment-variables.md +325 -0
- package/dist/skill/docs/stack/account-ui/features/admin.md +76 -0
- package/dist/skill/docs/stack/account-ui/features/api-keys.md +22 -0
- package/dist/skill/docs/stack/account-ui/features/avatars.md +37 -0
- package/dist/skill/docs/stack/account-ui/features/cli-authorize.md +21 -0
- package/dist/skill/docs/stack/account-ui/features/index.md +291 -0
- package/dist/skill/docs/stack/account-ui/features/organizations.md +29 -0
- package/dist/skill/docs/stack/account-ui/features/passkeys.md +31 -0
- package/dist/skill/docs/stack/account-ui/features/passwordless.md +28 -0
- package/dist/skill/docs/stack/account-ui/features/sessions.md +20 -0
- package/dist/skill/docs/stack/account-ui/hooks.md +209 -0
- package/dist/skill/docs/stack/account-ui/index.md +147 -0
- package/dist/skill/docs/stack/account-ui/library-usage.md +257 -0
- package/dist/skill/docs/stack/account-ui/standalone.md +149 -0
- package/dist/skill/docs/stack/account-ui/with-quickback.md +160 -0
- package/dist/skill/docs/stack/account-ui/worker.md +362 -0
- package/dist/skill/docs/stack/auth/api-keys.md +15 -0
- package/dist/skill/docs/stack/auth/device-auth.md +14 -0
- package/dist/skill/docs/stack/auth/index.md +64 -0
- package/dist/skill/docs/stack/auth/jwt-optimization.md +245 -0
- package/dist/skill/docs/stack/auth/plugins/aws-ses.md +127 -0
- package/dist/skill/docs/stack/auth/plugins/combo-auth.md +74 -0
- package/dist/skill/docs/stack/auth/plugins/index.md +228 -0
- package/dist/skill/docs/stack/auth/plugins/upgrade-anonymous.md +155 -0
- package/dist/skill/docs/stack/auth/security.md +455 -0
- package/dist/skill/docs/stack/auth/using-auth.md +39 -0
- package/dist/skill/docs/stack/cms/actions.md +199 -0
- package/dist/skill/docs/stack/cms/components.md +479 -0
- package/dist/skill/docs/stack/cms/connecting.md +199 -0
- package/dist/skill/docs/stack/cms/dashboard.md +39 -0
- package/dist/skill/docs/stack/cms/index.md +158 -0
- package/dist/skill/docs/stack/cms/inline-editing.md +136 -0
- package/dist/skill/docs/stack/cms/pages.md +275 -0
- package/dist/skill/docs/stack/cms/record-layouts.md +151 -0
- package/dist/skill/docs/stack/cms/schema-format.md +437 -0
- package/dist/skill/docs/stack/cms/schema-registry.md +200 -0
- package/dist/skill/docs/stack/cms/security.md +203 -0
- package/dist/skill/docs/stack/cms/table-views.md +142 -0
- package/dist/skill/docs/stack/index.md +65 -0
- package/dist/skill/docs/stack/queues/handlers.md +317 -0
- package/dist/skill/docs/stack/queues/index.md +56 -0
- package/dist/skill/docs/stack/queues/using-queues.md +192 -0
- package/dist/skill/docs/stack/realtime/durable-objects.md +488 -0
- package/dist/skill/docs/stack/realtime/index.md +67 -0
- package/dist/skill/docs/stack/realtime/using-realtime.md +211 -0
- package/dist/skill/docs/stack/storage/index.md +17 -0
- package/dist/skill/docs/stack/storage/kv.md +204 -0
- package/dist/skill/docs/stack/storage/r2.md +232 -0
- package/dist/skill/docs/stack/storage/using-kv.md +70 -0
- package/dist/skill/docs/stack/storage/using-r2.md +55 -0
- package/dist/skill/docs/stack/vector/embeddings.md +554 -0
- package/dist/skill/docs/stack/vector/index.md +44 -0
- package/dist/skill/docs/stack/vector/using-embeddings.md +186 -0
- package/dist/skill/docs/stack/webhooks/inbound.md +186 -0
- package/dist/skill/docs/stack/webhooks/index.md +36 -0
- package/dist/skill/docs/stack/webhooks/outbound.md +281 -0
- package/package.json +1 -1
- package/src/skill/SKILL.md +142 -1051
- package/src/skill/agents/quickback-specialist/AGENT.md +36 -0
- package/src/skill/docs/changelog.md +1192 -0
- package/src/skill/docs/compiler/claude-code-skill.md +312 -0
- package/src/skill/docs/compiler/cloud-compiler/authentication.md +63 -0
- package/src/skill/docs/compiler/cloud-compiler/cli.md +307 -0
- package/src/skill/docs/compiler/cloud-compiler/endpoints.md +78 -0
- package/src/skill/docs/compiler/cloud-compiler/index.md +65 -0
- package/src/skill/docs/compiler/cloud-compiler/local-compiler.md +115 -0
- package/src/skill/docs/compiler/cloud-compiler/troubleshooting.md +76 -0
- package/src/skill/docs/compiler/config/agents.md +144 -0
- package/src/skill/docs/compiler/config/auth.md +109 -0
- package/src/skill/docs/compiler/config/bindings.md +176 -0
- package/src/skill/docs/compiler/config/domains.md +149 -0
- package/src/skill/docs/compiler/config/index.md +419 -0
- package/src/skill/docs/compiler/config/output.md +338 -0
- package/src/skill/docs/compiler/config/providers.md +248 -0
- package/src/skill/docs/compiler/config/security.md +255 -0
- package/src/skill/docs/compiler/config/single-tenant.md +128 -0
- package/src/skill/docs/compiler/config/variables.md +157 -0
- package/src/skill/docs/compiler/definitions/access.md +445 -0
- package/src/skill/docs/compiler/definitions/actions.md +884 -0
- package/src/skill/docs/compiler/definitions/concepts.md +52 -0
- package/src/skill/docs/compiler/definitions/feature.md +164 -0
- package/src/skill/docs/compiler/definitions/firewall.md +285 -0
- package/src/skill/docs/compiler/definitions/guards.md +241 -0
- package/src/skill/docs/compiler/definitions/index.md +219 -0
- package/src/skill/docs/compiler/definitions/masking.md +241 -0
- package/src/skill/docs/compiler/definitions/read.md +220 -0
- package/src/skill/docs/compiler/definitions/schema.md +697 -0
- package/src/skill/docs/compiler/definitions/validation.md +35 -0
- package/src/skill/docs/compiler/definitions/views.md +292 -0
- package/src/skill/docs/compiler/getting-started/claude-code.md +126 -0
- package/src/skill/docs/compiler/getting-started/full-example.md +431 -0
- package/src/skill/docs/compiler/getting-started/hand-crafted.md +178 -0
- package/src/skill/docs/compiler/getting-started/index.md +192 -0
- package/src/skill/docs/compiler/getting-started/patterns.md +225 -0
- package/src/skill/docs/compiler/getting-started/template-blog.md +280 -0
- package/src/skill/docs/compiler/getting-started/template-cloudflare.md +260 -0
- package/src/skill/docs/compiler/getting-started/template-empty.md +112 -0
- package/src/skill/docs/compiler/getting-started/templates.md +111 -0
- package/src/skill/docs/compiler/index.md +85 -0
- package/src/skill/docs/compiler/targets/hono-api/cloudflare.md +94 -0
- package/src/skill/docs/compiler/targets/hono-api/database/d1.md +246 -0
- package/src/skill/docs/compiler/targets/hono-api/database/index.md +16 -0
- package/src/skill/docs/compiler/targets/hono-api/database/neon.md +144 -0
- package/src/skill/docs/compiler/targets/hono-api/database/using-d1.md +39 -0
- package/src/skill/docs/compiler/targets/hono-api/index.md +37 -0
- package/src/skill/docs/compiler/targets/hono-api/using-the-api/actions-api.md +323 -0
- package/src/skill/docs/compiler/targets/hono-api/using-the-api/batch-operations.md +357 -0
- package/src/skill/docs/compiler/targets/hono-api/using-the-api/caching.md +105 -0
- package/src/skill/docs/compiler/targets/hono-api/using-the-api/crud.md +652 -0
- package/src/skill/docs/compiler/targets/hono-api/using-the-api/errors.md +224 -0
- package/src/skill/docs/compiler/targets/hono-api/using-the-api/index.md +37 -0
- package/src/skill/docs/compiler/targets/hono-api/using-the-api/openapi.md +203 -0
- package/src/skill/docs/compiler/targets/hono-api/using-the-api/query-params.md +199 -0
- package/src/skill/docs/compiler/targets/hono-api/using-the-api/views-api.md +161 -0
- package/src/skill/docs/compiler/targets/index.md +47 -0
- package/src/skill/docs/compiler/targets/supabase-rls/index.md +55 -0
- package/src/skill/docs/compiler/targets/supabase-rls/limitations.md +48 -0
- package/src/skill/docs/compiler/targets/supabase-rls/mappings.md +99 -0
- package/src/skill/docs/compiler/targets/supabase-rls/setup.md +88 -0
- package/src/skill/docs/compiler/troubleshooting.md +120 -0
- package/src/skill/docs/index.md +77 -0
- package/src/skill/docs/stack/account-ui/customization.md +378 -0
- package/src/skill/docs/stack/account-ui/environment-variables.md +325 -0
- package/src/skill/docs/stack/account-ui/features/admin.md +76 -0
- package/src/skill/docs/stack/account-ui/features/api-keys.md +22 -0
- package/src/skill/docs/stack/account-ui/features/avatars.md +37 -0
- package/src/skill/docs/stack/account-ui/features/cli-authorize.md +21 -0
- package/src/skill/docs/stack/account-ui/features/index.md +291 -0
- package/src/skill/docs/stack/account-ui/features/organizations.md +29 -0
- package/src/skill/docs/stack/account-ui/features/passkeys.md +31 -0
- package/src/skill/docs/stack/account-ui/features/passwordless.md +28 -0
- package/src/skill/docs/stack/account-ui/features/sessions.md +20 -0
- package/src/skill/docs/stack/account-ui/hooks.md +209 -0
- package/src/skill/docs/stack/account-ui/index.md +147 -0
- package/src/skill/docs/stack/account-ui/library-usage.md +257 -0
- package/src/skill/docs/stack/account-ui/standalone.md +149 -0
- package/src/skill/docs/stack/account-ui/with-quickback.md +160 -0
- package/src/skill/docs/stack/account-ui/worker.md +362 -0
- package/src/skill/docs/stack/auth/api-keys.md +15 -0
- package/src/skill/docs/stack/auth/device-auth.md +14 -0
- package/src/skill/docs/stack/auth/index.md +64 -0
- package/src/skill/docs/stack/auth/jwt-optimization.md +245 -0
- package/src/skill/docs/stack/auth/plugins/aws-ses.md +127 -0
- package/src/skill/docs/stack/auth/plugins/combo-auth.md +74 -0
- package/src/skill/docs/stack/auth/plugins/index.md +228 -0
- package/src/skill/docs/stack/auth/plugins/upgrade-anonymous.md +155 -0
- package/src/skill/docs/stack/auth/security.md +455 -0
- package/src/skill/docs/stack/auth/using-auth.md +39 -0
- package/src/skill/docs/stack/cms/actions.md +199 -0
- package/src/skill/docs/stack/cms/components.md +479 -0
- package/src/skill/docs/stack/cms/connecting.md +199 -0
- package/src/skill/docs/stack/cms/dashboard.md +39 -0
- package/src/skill/docs/stack/cms/index.md +158 -0
- package/src/skill/docs/stack/cms/inline-editing.md +136 -0
- package/src/skill/docs/stack/cms/pages.md +275 -0
- package/src/skill/docs/stack/cms/record-layouts.md +151 -0
- package/src/skill/docs/stack/cms/schema-format.md +437 -0
- package/src/skill/docs/stack/cms/schema-registry.md +200 -0
- package/src/skill/docs/stack/cms/security.md +203 -0
- package/src/skill/docs/stack/cms/table-views.md +142 -0
- package/src/skill/docs/stack/index.md +65 -0
- package/src/skill/docs/stack/queues/handlers.md +317 -0
- package/src/skill/docs/stack/queues/index.md +56 -0
- package/src/skill/docs/stack/queues/using-queues.md +192 -0
- package/src/skill/docs/stack/realtime/durable-objects.md +488 -0
- package/src/skill/docs/stack/realtime/index.md +67 -0
- package/src/skill/docs/stack/realtime/using-realtime.md +211 -0
- package/src/skill/docs/stack/storage/index.md +17 -0
- package/src/skill/docs/stack/storage/kv.md +204 -0
- package/src/skill/docs/stack/storage/r2.md +232 -0
- package/src/skill/docs/stack/storage/using-kv.md +70 -0
- package/src/skill/docs/stack/storage/using-r2.md +55 -0
- package/src/skill/docs/stack/vector/embeddings.md +554 -0
- package/src/skill/docs/stack/vector/index.md +44 -0
- package/src/skill/docs/stack/vector/using-embeddings.md +186 -0
- package/src/skill/docs/stack/webhooks/inbound.md +186 -0
- package/src/skill/docs/stack/webhooks/index.md +36 -0
- package/src/skill/docs/stack/webhooks/outbound.md +281 -0
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
# Quickback Documentation
|
|
2
|
+
|
|
3
|
+
Quickback is a **backend compiler**. Define your database schema and security rules in TypeScript — Quickback compiles them into a Hono API or PostgreSQL Row Level Security policies. Pair the output with the Quickback Stack for a complete Supabase alternative on Cloudflare.
|
|
4
|
+
|
|
5
|
+
## Quick start
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install -g @quickback-dev/cli
|
|
9
|
+
quickback create cloudflare my-app
|
|
10
|
+
cd my-app
|
|
11
|
+
quickback compile
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
## How it works
|
|
15
|
+
|
|
16
|
+
Write ~50 lines of definitions. Get a production codebase.
|
|
17
|
+
|
|
18
|
+
```
|
|
19
|
+
defineTable() ─┐
|
|
20
|
+
├─► Compiler ─► Hono API (Cloudflare D1 / Neon)
|
|
21
|
+
defineActions()─┘ └► RLS policies (Supabase)
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
Every API request passes through four security layers:
|
|
25
|
+
|
|
26
|
+
```
|
|
27
|
+
Request → Firewall → Access → Guards → Masking → Response
|
|
28
|
+
│ │ │ │
|
|
29
|
+
│ │ │ └── Hide sensitive fields
|
|
30
|
+
│ │ └── Block field modifications
|
|
31
|
+
│ └── Check roles & conditions
|
|
32
|
+
└── Isolate data by owner/org
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
**Secure by default.** Nothing is accessible until you explicitly open it up. See [Definitions](/compiler/definitions) for the full security model.
|
|
36
|
+
|
|
37
|
+
---
|
|
38
|
+
|
|
39
|
+
## The two products
|
|
40
|
+
|
|
41
|
+
### Quickback Compiler
|
|
42
|
+
|
|
43
|
+
[**Quickback Compiler**](/compiler) — the build tool. Define your schema and security rules in TypeScript and compile to one of two targets:
|
|
44
|
+
|
|
45
|
+
- **[Quickback for Hono API](/compiler/targets/hono-api)** — A complete Hono application on Cloudflare D1 or Neon, with CRUD, batch endpoints, OpenAPI, and an MCP server.
|
|
46
|
+
- **[Quickback for Supabase](/compiler/targets/supabase-rls)** — PostgreSQL Row Level Security policies for Supabase. Keep Supabase Auth, Storage, and Realtime; Quickback adds the security layer.
|
|
47
|
+
|
|
48
|
+
The same `defineTable()` definitions work for both targets.
|
|
49
|
+
|
|
50
|
+
**Start here:**
|
|
51
|
+
- **[Getting Started](/compiler/getting-started)** — Create your first project
|
|
52
|
+
- **[Definitions](/compiler/definitions)** — Schema, Firewall, Access, Guards, Masking, Views, Actions
|
|
53
|
+
- **[Cloud Compiler](/compiler/cloud-compiler)** — CLI, MCP server, authentication
|
|
54
|
+
- **[Claude Code Skill](/compiler/claude-code-skill)** — AI-powered authoring assistance
|
|
55
|
+
|
|
56
|
+
---
|
|
57
|
+
|
|
58
|
+
### Quickback Stack
|
|
59
|
+
|
|
60
|
+
The runtime services around your compiled code. Everything you need for a complete Supabase alternative on Cloudflare:
|
|
61
|
+
|
|
62
|
+
- **[Auth](/stack/auth)** — Better Auth with email OTP, passkeys, organizations, admin
|
|
63
|
+
- **[Storage](/stack/storage)** — KV (sessions, cache) and R2 (files)
|
|
64
|
+
- **[Realtime](/stack/realtime)** — Durable Objects + WebSocket
|
|
65
|
+
- **[Queues](/stack/queues)** — Background jobs and webhook delivery
|
|
66
|
+
- **[Vector & AI](/stack/vector)** — Embeddings, semantic search
|
|
67
|
+
- **[Webhooks](/stack/webhooks)** — Inbound (signed) and outbound (retried)
|
|
68
|
+
- **[Quickback CMS](/stack/cms)** — Schema-driven admin UI
|
|
69
|
+
- **[Account UI](/stack/account-ui)** — Pre-built auth and profile pages
|
|
70
|
+
|
|
71
|
+
Everything runs on **your own Cloudflare account** — no Quickback infrastructure between you and your data.
|
|
72
|
+
|
|
73
|
+
---
|
|
74
|
+
|
|
75
|
+
### Changelog
|
|
76
|
+
|
|
77
|
+
[**Changelog**](/changelog) — what's new in Quickback. Release notes, new features, and improvements.
|
|
@@ -0,0 +1,378 @@
|
|
|
1
|
+
# Customization
|
|
2
|
+
|
|
3
|
+
Customize the Account UI to match your brand and messaging.
|
|
4
|
+
|
|
5
|
+
**Standalone (template):** Configure via environment variables, edit `src/config/app.ts` directly, or use `setAppConfig()` for runtime overrides.
|
|
6
|
+
|
|
7
|
+
**Library (npm):** Configure entirely via `setAppConfig()`. Import it from `quickback-better-auth-account-ui` instead of `@/config/app`.
|
|
8
|
+
|
|
9
|
+
> **Library imports**
|
|
10
|
+
>
|
|
11
|
+
> All `setAppConfig` examples below use the standalone import path (`@/config/app`). If you're using library mode, replace with:
|
|
12
|
+
> ```ts
|
|
13
|
+
> import { setAppConfig } from 'quickback-better-auth-account-ui';
|
|
14
|
+
> ```
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
## Branding
|
|
18
|
+
|
|
19
|
+
### App Identity
|
|
20
|
+
|
|
21
|
+
Set your application's name and description:
|
|
22
|
+
|
|
23
|
+
```bash
|
|
24
|
+
VITE_APP_NAME=Acme SaaS
|
|
25
|
+
VITE_APP_TAGLINE=Build faster, ship sooner
|
|
26
|
+
VITE_APP_DESCRIPTION=The complete platform for modern web applications
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
These values appear in:
|
|
30
|
+
- Page titles (`<title>Acme SaaS | Login</title>`)
|
|
31
|
+
- Meta descriptions
|
|
32
|
+
- UI headers and footers
|
|
33
|
+
- Email templates
|
|
34
|
+
|
|
35
|
+
### Visual Identity
|
|
36
|
+
|
|
37
|
+
```bash
|
|
38
|
+
# Primary theme color (used for buttons, links, accents)
|
|
39
|
+
VITE_THEME_COLOR=#3b82f6
|
|
40
|
+
|
|
41
|
+
# Company name (shown in footer, legal pages)
|
|
42
|
+
VITE_COMPANY_NAME=Acme Corporation
|
|
43
|
+
|
|
44
|
+
# Company address (shown in footer, receipts)
|
|
45
|
+
VITE_COMPANY_ADDRESS=123 Main St, Suite 100, San Francisco, CA 94105
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
### Logo and Favicon
|
|
49
|
+
|
|
50
|
+
Place your branding assets in the `public/` directory:
|
|
51
|
+
|
|
52
|
+
```
|
|
53
|
+
public/
|
|
54
|
+
├── logo.png # Main logo (shown in header)
|
|
55
|
+
├── favicon.ico # Browser favicon
|
|
56
|
+
└── og-image.png # Social media preview image
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
Then update the paths in `src/config/app.ts`:
|
|
60
|
+
|
|
61
|
+
```ts title="src/config/app.ts"
|
|
62
|
+
branding: {
|
|
63
|
+
primaryColor: "#1e293b",
|
|
64
|
+
logoUrl: "/logo.png",
|
|
65
|
+
faviconUrl: "/favicon.ico"
|
|
66
|
+
},
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
Or set them at runtime in `src/main.tsx`:
|
|
70
|
+
|
|
71
|
+
```ts
|
|
72
|
+
import { setAppConfig } from '@/config/app';
|
|
73
|
+
|
|
74
|
+
setAppConfig({
|
|
75
|
+
branding: {
|
|
76
|
+
logoUrl: '/logo.png',
|
|
77
|
+
faviconUrl: '/favicon.ico',
|
|
78
|
+
},
|
|
79
|
+
});
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
## Custom Labels
|
|
83
|
+
|
|
84
|
+
Override default UI labels using runtime configuration:
|
|
85
|
+
|
|
86
|
+
```ts
|
|
87
|
+
import { setAppConfig } from '@/config/app';
|
|
88
|
+
|
|
89
|
+
setAppConfig({
|
|
90
|
+
labels: {
|
|
91
|
+
terms: 'Terms and Conditions',
|
|
92
|
+
privacy: 'Privacy Notice',
|
|
93
|
+
support: 'Help Center',
|
|
94
|
+
company: 'My Company',
|
|
95
|
+
organizations: 'Workspaces', // Rename "Organizations" to "Workspaces"
|
|
96
|
+
},
|
|
97
|
+
});
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
### Available Labels
|
|
101
|
+
|
|
102
|
+
| Label | Default | Usage |
|
|
103
|
+
|-------|---------|-------|
|
|
104
|
+
| `terms` | "Terms of Service" | Footer link text |
|
|
105
|
+
| `privacy` | "Privacy Policy" | Footer link text |
|
|
106
|
+
| `support` | "Contact Support" | Footer link text |
|
|
107
|
+
| `company` | (from `VITE_COMPANY_NAME`) | Footer company name |
|
|
108
|
+
| `organizations` | "Organizations" | Navigation and page titles |
|
|
109
|
+
|
|
110
|
+
## Custom Messages
|
|
111
|
+
|
|
112
|
+
Customize user-facing messages:
|
|
113
|
+
|
|
114
|
+
```ts
|
|
115
|
+
import { setAppConfig } from '@/config/app';
|
|
116
|
+
|
|
117
|
+
setAppConfig({
|
|
118
|
+
messages: {
|
|
119
|
+
noOrganizations: "You haven't joined any workspaces yet.",
|
|
120
|
+
contactAdminForInvite: "Contact your team lead to get access.",
|
|
121
|
+
noPendingInvitations: "No pending invites at this time",
|
|
122
|
+
createOrganization: "Create Workspace",
|
|
123
|
+
// ... more messages
|
|
124
|
+
},
|
|
125
|
+
});
|
|
126
|
+
```
|
|
127
|
+
|
|
128
|
+
### Available Messages
|
|
129
|
+
|
|
130
|
+
| Message | Default | Usage |
|
|
131
|
+
|---------|---------|-------|
|
|
132
|
+
| `noOrganizations` | "You're not a member of any organizations yet." | Empty organizations list |
|
|
133
|
+
| `contactAdminForInvite` | "Contact an admin to be invited to an organization." | Organizations page help text |
|
|
134
|
+
| `noPendingInvitations` | "You have no pending invitations" | Empty invitations list |
|
|
135
|
+
| `createOrganization` | "Create Organization" | Button text |
|
|
136
|
+
| `accountInformation` | "Account Information" | Profile section header |
|
|
137
|
+
| `timezone` | "Timezone" | Label for timezone field |
|
|
138
|
+
| `serverLocation` | "Server Location" | Label for server location |
|
|
139
|
+
| `memberSince` | "Member since" | Account age label |
|
|
140
|
+
| `pendingInvitations` | "Pending Invitations" | Section header |
|
|
141
|
+
| `invitedAs` | "Invited as" | Invitation role label |
|
|
142
|
+
| `accept` | "Accept" | Accept invitation button |
|
|
143
|
+
| `decline` | "Decline" | Decline invitation button |
|
|
144
|
+
| `userFallback` | "User" | Fallback for missing name |
|
|
145
|
+
| `noEmailProvided` | "No email provided" | Fallback for missing email |
|
|
146
|
+
| `more` | "More" | Pagination/load more text |
|
|
147
|
+
| `total` | "total" | Total count label |
|
|
148
|
+
| `active` | "Active" | Active status label |
|
|
149
|
+
| `new` | "New" | New item label |
|
|
150
|
+
|
|
151
|
+
## Route Customization
|
|
152
|
+
|
|
153
|
+
Customize route paths using runtime configuration:
|
|
154
|
+
|
|
155
|
+
```ts
|
|
156
|
+
import { setAppConfig } from '@/config/app';
|
|
157
|
+
|
|
158
|
+
setAppConfig({
|
|
159
|
+
routes: {
|
|
160
|
+
public: {
|
|
161
|
+
home: '/',
|
|
162
|
+
login: '/sign-in', // Change from /login
|
|
163
|
+
signup: '/sign-up', // Change from /signup
|
|
164
|
+
forgotPassword: '/reset-password',
|
|
165
|
+
welcome: '/getting-started',
|
|
166
|
+
},
|
|
167
|
+
authenticated: {
|
|
168
|
+
dashboard: '/dashboard',
|
|
169
|
+
profile: '/my-account',
|
|
170
|
+
settings: '/preferences',
|
|
171
|
+
},
|
|
172
|
+
organizations: {
|
|
173
|
+
list: '/workspaces', // Rename route
|
|
174
|
+
create: '/workspaces/new',
|
|
175
|
+
detail: (slug) => `/workspaces/${slug}`,
|
|
176
|
+
},
|
|
177
|
+
},
|
|
178
|
+
});
|
|
179
|
+
```
|
|
180
|
+
|
|
181
|
+
> **Route Configuration Limitations**
|
|
182
|
+
>
|
|
183
|
+
> Route changes via runtime config only affect client-side routing and internal links. External links to your Account UI should use the actual deployed routes (default paths).
|
|
184
|
+
|
|
185
|
+
|
|
186
|
+
## Password Requirements
|
|
187
|
+
|
|
188
|
+
Customize password validation rules:
|
|
189
|
+
|
|
190
|
+
```ts
|
|
191
|
+
import { setAppConfig } from '@/config/app';
|
|
192
|
+
|
|
193
|
+
setAppConfig({
|
|
194
|
+
auth: {
|
|
195
|
+
passwordRequirements: {
|
|
196
|
+
minLength: 12, // Minimum password length
|
|
197
|
+
maxLength: 128, // Maximum password length
|
|
198
|
+
requireUppercase: true, // Must have uppercase letter
|
|
199
|
+
requireLowercase: true, // Must have lowercase letter
|
|
200
|
+
requireNumbers: true, // Must have number
|
|
201
|
+
requireSymbols: true, // Must have special character
|
|
202
|
+
},
|
|
203
|
+
},
|
|
204
|
+
});
|
|
205
|
+
```
|
|
206
|
+
|
|
207
|
+
Password requirements are displayed to users during signup and password changes.
|
|
208
|
+
|
|
209
|
+
## Session Duration
|
|
210
|
+
|
|
211
|
+
Control how long users stay logged in:
|
|
212
|
+
|
|
213
|
+
```ts
|
|
214
|
+
import { setAppConfig } from '@/config/app';
|
|
215
|
+
|
|
216
|
+
setAppConfig({
|
|
217
|
+
auth: {
|
|
218
|
+
sessionDuration: 7 * 24 * 60 * 60, // 7 days in seconds
|
|
219
|
+
},
|
|
220
|
+
});
|
|
221
|
+
```
|
|
222
|
+
|
|
223
|
+
## Email Customization
|
|
224
|
+
|
|
225
|
+
Configure email sender information:
|
|
226
|
+
|
|
227
|
+
```bash
|
|
228
|
+
VITE_EMAIL_FROM=noreply@acme.com
|
|
229
|
+
VITE_EMAIL_REPLY_TO=support@acme.com
|
|
230
|
+
VITE_SUPPORT_EMAIL=help@acme.com
|
|
231
|
+
```
|
|
232
|
+
|
|
233
|
+
The `fromName` is automatically set to `VITE_APP_NAME`:
|
|
234
|
+
|
|
235
|
+
```ts
|
|
236
|
+
// Emails will show:
|
|
237
|
+
// From: "Acme SaaS <noreply@acme.com>"
|
|
238
|
+
```
|
|
239
|
+
|
|
240
|
+
## URL Configuration
|
|
241
|
+
|
|
242
|
+
Configure URLs for external links:
|
|
243
|
+
|
|
244
|
+
```bash
|
|
245
|
+
# Main application (redirected to after login)
|
|
246
|
+
VITE_QUICKBACK_APP_URL=https://app.acme.com
|
|
247
|
+
|
|
248
|
+
# Organization/tenant URL pattern
|
|
249
|
+
VITE_TENANT_URL_PATTERN=/workspace/{slug}
|
|
250
|
+
|
|
251
|
+
# Support pages
|
|
252
|
+
VITE_SUPPORT_URL=https://help.acme.com
|
|
253
|
+
VITE_PRIVACY_URL=https://acme.com/legal/privacy
|
|
254
|
+
VITE_TERMS_URL=https://acme.com/legal/terms
|
|
255
|
+
```
|
|
256
|
+
|
|
257
|
+
### Tenant URL Patterns
|
|
258
|
+
|
|
259
|
+
The tenant URL pattern supports flexible organization routing:
|
|
260
|
+
|
|
261
|
+
```bash
|
|
262
|
+
# Path-based routing
|
|
263
|
+
VITE_TENANT_URL_PATTERN=/organizations/{slug}
|
|
264
|
+
# Result: https://app.acme.com/organizations/acme-corp
|
|
265
|
+
|
|
266
|
+
# Subdomain routing
|
|
267
|
+
VITE_TENANT_URL_PATTERN=https://{slug}.acme.com
|
|
268
|
+
# Result: https://acme-corp.acme.com
|
|
269
|
+
|
|
270
|
+
# Custom pattern
|
|
271
|
+
VITE_TENANT_URL_PATTERN=/workspace/{slug}/dashboard
|
|
272
|
+
# Result: https://app.acme.com/workspace/acme-corp/dashboard
|
|
273
|
+
```
|
|
274
|
+
|
|
275
|
+
## Complete Customization Example
|
|
276
|
+
|
|
277
|
+
Here's a complete example showing all customization options:
|
|
278
|
+
|
|
279
|
+
```ts title="src/main.tsx"
|
|
280
|
+
import { StrictMode } from 'react';
|
|
281
|
+
import { createRoot } from 'react-dom/client';
|
|
282
|
+
import { setAppConfig } from '@/config/app';
|
|
283
|
+
import './app/globals.css';
|
|
284
|
+
import './custom-styles.css'; // Your custom CSS overrides
|
|
285
|
+
|
|
286
|
+
// Apply customizations before rendering
|
|
287
|
+
setAppConfig({
|
|
288
|
+
name: 'Acme SaaS',
|
|
289
|
+
tagline: 'Build faster, ship sooner',
|
|
290
|
+
description: 'The complete platform for modern web applications',
|
|
291
|
+
|
|
292
|
+
branding: {
|
|
293
|
+
primaryColor: '#3b82f6',
|
|
294
|
+
logoUrl: '/acme-logo.png',
|
|
295
|
+
faviconUrl: '/favicon.ico',
|
|
296
|
+
},
|
|
297
|
+
|
|
298
|
+
labels: {
|
|
299
|
+
organizations: 'Workspaces',
|
|
300
|
+
terms: 'Terms and Conditions',
|
|
301
|
+
privacy: 'Privacy Notice',
|
|
302
|
+
support: 'Help Center',
|
|
303
|
+
},
|
|
304
|
+
|
|
305
|
+
messages: {
|
|
306
|
+
noOrganizations: "You haven't joined any workspaces yet.",
|
|
307
|
+
createOrganization: 'Create Workspace',
|
|
308
|
+
contactAdminForInvite: 'Contact your team lead for access.',
|
|
309
|
+
},
|
|
310
|
+
|
|
311
|
+
routes: {
|
|
312
|
+
public: {
|
|
313
|
+
login: '/sign-in',
|
|
314
|
+
signup: '/sign-up',
|
|
315
|
+
},
|
|
316
|
+
organizations: {
|
|
317
|
+
list: '/workspaces',
|
|
318
|
+
create: '/workspaces/new',
|
|
319
|
+
detail: (slug) => `/workspaces/${slug}`,
|
|
320
|
+
},
|
|
321
|
+
},
|
|
322
|
+
|
|
323
|
+
auth: {
|
|
324
|
+
passwordRequirements: {
|
|
325
|
+
minLength: 12,
|
|
326
|
+
requireSymbols: true,
|
|
327
|
+
},
|
|
328
|
+
sessionDuration: 7 * 24 * 60 * 60, // 7 days
|
|
329
|
+
},
|
|
330
|
+
});
|
|
331
|
+
|
|
332
|
+
// Render app
|
|
333
|
+
import App from './App';
|
|
334
|
+
const root = document.getElementById('root')!;
|
|
335
|
+
createRoot(root).render(
|
|
336
|
+
<StrictMode>
|
|
337
|
+
<App />
|
|
338
|
+
</StrictMode>
|
|
339
|
+
);
|
|
340
|
+
```
|
|
341
|
+
|
|
342
|
+
## Custom Styles
|
|
343
|
+
|
|
344
|
+
Override default styles with custom CSS:
|
|
345
|
+
|
|
346
|
+
```css title="custom-styles.css"
|
|
347
|
+
/* Override primary color */
|
|
348
|
+
:root {
|
|
349
|
+
--primary: 59 130 246; /* Tailwind blue-500 */
|
|
350
|
+
--primary-foreground: 255 255 255;
|
|
351
|
+
}
|
|
352
|
+
|
|
353
|
+
/* Custom logo size */
|
|
354
|
+
.logo {
|
|
355
|
+
width: 180px;
|
|
356
|
+
height: auto;
|
|
357
|
+
}
|
|
358
|
+
|
|
359
|
+
/* Custom button styles */
|
|
360
|
+
.btn-primary {
|
|
361
|
+
background-color: var(--primary);
|
|
362
|
+
border-radius: 8px;
|
|
363
|
+
font-weight: 600;
|
|
364
|
+
}
|
|
365
|
+
```
|
|
366
|
+
|
|
367
|
+
Import your custom CSS after the Account UI styles:
|
|
368
|
+
|
|
369
|
+
```ts
|
|
370
|
+
import './app/globals.css';
|
|
371
|
+
import './custom-styles.css'; // Your overrides
|
|
372
|
+
```
|
|
373
|
+
|
|
374
|
+
## Next Steps
|
|
375
|
+
|
|
376
|
+
- **[Worker Setup](/stack/account-ui/worker)** - Deploy your customized UI
|
|
377
|
+
- **[Environment Variables](/stack/account-ui/environment-variables)** - Complete configuration reference
|
|
378
|
+
- **[Feature Flags](/stack/account-ui/features)** - Enable/disable features
|