@percepta/create 3.6.3 → 4.0.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.
Files changed (44) hide show
  1. package/dist/index.js +5 -3
  2. package/dist/index.js.map +1 -1
  3. package/package.json +1 -1
  4. package/templates/library/README.md +5 -2
  5. package/templates/library/gitignore.template +1 -0
  6. package/templates/library/package.json.template +17 -13
  7. package/templates/library/src/index.test.ts +8 -0
  8. package/templates/library/tsconfig.json +1 -17
  9. package/templates/library/tsdown.config.ts +3 -0
  10. package/templates/library/vitest.config.ts +3 -0
  11. package/templates/monorepo/.dockerignore +1 -0
  12. package/templates/monorepo/.github/CODEOWNERS +67 -0
  13. package/templates/monorepo/.github/actions/ci/action.yml +56 -0
  14. package/templates/monorepo/.github/workflows/build-and-publish.yml +22 -0
  15. package/templates/monorepo/.github/workflows/pr-build.yml +21 -0
  16. package/templates/monorepo/.node-version +1 -0
  17. package/templates/monorepo/auth/package.json +4 -4
  18. package/templates/monorepo/auth/src/auth.ts +0 -1
  19. package/templates/monorepo/auth/tsconfig.json +1 -10
  20. package/templates/monorepo/gitignore.template +1 -0
  21. package/templates/monorepo/oxfmt.config.ts.template +3 -0
  22. package/templates/monorepo/oxlint.config.ts.template +3 -0
  23. package/templates/monorepo/package.json.template +17 -9
  24. package/templates/monorepo/turbo.json +20 -0
  25. package/templates/webapp/.node-version +0 -1
  26. package/templates/webapp/AGENTS.md +20 -15
  27. package/templates/webapp/README.md +2 -2
  28. package/templates/webapp/globals.d.ts +1 -0
  29. package/templates/webapp/oxfmt.config.ts.template +5 -0
  30. package/templates/webapp/package.json.template +14 -22
  31. package/templates/webapp/scripts/seed.ts +1 -1
  32. package/templates/webapp/src/app/global-error.tsx +1 -1
  33. package/templates/webapp/src/config/isDev.ts +0 -2
  34. package/templates/webapp/src/drizzle/db.ts +2 -2
  35. package/templates/webapp/src/lib/auth-client.ts +6 -3
  36. package/templates/webapp/tsconfig.json +1 -12
  37. package/templates/webapp/vitest.config.ts +3 -7
  38. package/templates/library/eslint.config.js +0 -10
  39. package/templates/monorepo/eslint.config.js +0 -10
  40. package/templates/monorepo/tsconfig.json +0 -16
  41. package/templates/webapp/.github/workflows/ci.yml +0 -149
  42. package/templates/webapp/.prettierrc.mjs +0 -5
  43. package/templates/webapp/eslint.config.mjs +0 -100
  44. package/templates/webapp/npmrc.template +0 -4
@@ -1,19 +1,3 @@
1
1
  {
2
- "compilerOptions": {
3
- "target": "ES2022",
4
- "lib": ["ES2022"],
5
- "module": "NodeNext",
6
- "moduleResolution": "NodeNext",
7
- "strict": true,
8
- "esModuleInterop": true,
9
- "skipLibCheck": true,
10
- "forceConsistentCasingInFileNames": true,
11
- "declaration": true,
12
- "declarationMap": true,
13
- "sourceMap": true,
14
- "outDir": "dist",
15
- "rootDir": "src"
16
- },
17
- "include": ["src/**/*"],
18
- "exclude": ["node_modules", "dist"]
2
+ "extends": "@percepta/build/tsconfig/library"
19
3
  }
@@ -0,0 +1,3 @@
1
+ import { defineLibraryConfig } from "@percepta/build/tsdown";
2
+
3
+ export default defineLibraryConfig({ entry: "src/index.ts" });
@@ -0,0 +1,3 @@
1
+ import { createVitestConfig } from "@percepta/build/vitest";
2
+
3
+ export default createVitestConfig({});
@@ -8,6 +8,7 @@ dist
8
8
  build
9
9
  node_modules
10
10
  **/.next
11
+ **/.turbo
11
12
  **/node_modules
12
13
 
13
14
  .env
@@ -0,0 +1,67 @@
1
+ # CODEOWNERS itself:
2
+ /.github/CODEOWNERS @Percepta-Core/build-foundations
3
+
4
+ # Workspace configuration:
5
+ /pnpm-workspace.yaml @Percepta-Core/build-foundations
6
+ /pnpm-lock.yaml @Percepta-Core/build-foundations
7
+ /turbo.json @Percepta-Core/build-foundations
8
+ /package.json @Percepta-Core/build-foundations
9
+ **/turbo.json @Percepta-Core/build-foundations
10
+ **/package.json @Percepta-Core/build-foundations
11
+ **/.npmrc @Percepta-Core/build-foundations
12
+ **/.nvmrc @Percepta-Core/build-foundations
13
+ **/.node-version @Percepta-Core/build-foundations
14
+
15
+ # TypeScript configuration:
16
+ **/tsconfig*.json @Percepta-Core/build-foundations
17
+
18
+ # Linting and formatting:
19
+ **/oxlint.config.* @Percepta-Core/build-foundations
20
+ **/oxfmt.config.* @Percepta-Core/build-foundations
21
+ **/eslint.config.* @Percepta-Core/build-foundations
22
+ **/prettier.config.* @Percepta-Core/build-foundations
23
+
24
+ # Test runners and test infrastructure:
25
+ **/vitest*.config.* @Percepta-Core/build-foundations
26
+ **/vitest.setup.* @Percepta-Core/build-foundations
27
+ **/jest.config.* @Percepta-Core/build-foundations
28
+ **/playwright.config.* @Percepta-Core/build-foundations
29
+
30
+ # Bundlers, transpilers, framework configs, codegen:
31
+ **/tsdown.config.* @Percepta-Core/build-foundations
32
+ **/vite.config.* @Percepta-Core/build-foundations
33
+ **/rollup.config.* @Percepta-Core/build-foundations
34
+ **/webpack.config.* @Percepta-Core/build-foundations
35
+ **/esbuild.config.* @Percepta-Core/build-foundations
36
+ **/next.config.* @Percepta-Core/build-foundations
37
+ **/babel.config.* @Percepta-Core/build-foundations
38
+ **/swc.config.* @Percepta-Core/build-foundations
39
+ **/postcss.config.* @Percepta-Core/build-foundations
40
+ **/tailwind.config.* @Percepta-Core/build-foundations
41
+ **/drizzle.config.* @Percepta-Core/build-foundations
42
+ **/orval.config.* @Percepta-Core/build-foundations
43
+
44
+ # CI/CD:
45
+ /.github/ @Percepta-Core/build-foundations
46
+ **/.github/ @Percepta-Core/build-foundations
47
+
48
+ # Git hooks, repo metadata:
49
+ /.husky/ @Percepta-Core/build-foundations
50
+ **/.gitattributes @Percepta-Core/build-foundations
51
+ **/.gitignore @Percepta-Core/build-foundations
52
+
53
+ # Container, orchestration, deploy infrastructure:
54
+ /Dockerfile @Percepta-Core/build-foundations
55
+ /Dockerfile.* @Percepta-Core/build-foundations
56
+ **/Dockerfile @Percepta-Core/build-foundations
57
+ **/Dockerfile.* @Percepta-Core/build-foundations
58
+ /docker-compose*.yml @Percepta-Core/build-foundations
59
+ /docker-compose*.yaml @Percepta-Core/build-foundations
60
+ /.dockerignore @Percepta-Core/build-foundations
61
+ **/.dockerignore @Percepta-Core/build-foundations
62
+
63
+ # Workspace developer tooling (IDE, agents, in-editor settings):
64
+ /.vscode/ @Percepta-Core/build-foundations
65
+ /.cursor/ @Percepta-Core/build-foundations
66
+ /.codeium/ @Percepta-Core/build-foundations
67
+ /.windsurfrules @Percepta-Core/build-foundations
@@ -0,0 +1,56 @@
1
+ name: CI
2
+ description: Install dependencies, then build, typecheck, lint, format-check, migration-check, and test the workspace. Relies on Turbo's remote cache (when a token is provided) to dedupe work across invocations.
3
+
4
+ inputs:
5
+ turbo-token:
6
+ description: Turborepo remote cache token. Optional; without it, Turbo runs without remote cache.
7
+ required: false
8
+ turbo-team:
9
+ description: Turborepo team slug paired with `turbo-token`.
10
+ required: false
11
+
12
+ runs:
13
+ using: composite
14
+ steps:
15
+ - name: Setup PNPM
16
+ uses: pnpm/action-setup@v4
17
+
18
+ - name: Setup Node
19
+ uses: actions/setup-node@v4
20
+ with:
21
+ node-version-file: .node-version
22
+ cache: pnpm
23
+
24
+ - name: Install dependencies
25
+ shell: bash
26
+ env:
27
+ NPM_TOKEN: ${{ env.NPM_TOKEN }}
28
+ run: pnpm install --frozen-lockfile
29
+
30
+ - name: Fail if lockfile changed
31
+ shell: bash
32
+ run: git diff --exit-code pnpm-lock.yaml
33
+
34
+ - name: Build, typecheck, test
35
+ shell: bash
36
+ env:
37
+ NODE_OPTIONS: --max-old-space-size=4096
38
+ TURBO_TOKEN: ${{ inputs.turbo-token }}
39
+ TURBO_TEAM: ${{ inputs.turbo-team }}
40
+ run: pnpm exec turbo run build typecheck test --continue
41
+
42
+ - name: Lint
43
+ shell: bash
44
+ run: pnpm lint
45
+
46
+ - name: Format check
47
+ shell: bash
48
+ run: pnpm format --check
49
+
50
+ - name: Generate migration check
51
+ shell: bash
52
+ run: pnpm -r run db:generate
53
+
54
+ - name: Check for journal changes
55
+ shell: bash
56
+ run: git diff --exit-code -- '**/drizzle/migrations/meta/_journal.json'
@@ -0,0 +1,22 @@
1
+ name: Build and Publish
2
+
3
+ on:
4
+ push:
5
+ branches: [main]
6
+
7
+ env:
8
+ NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
9
+
10
+ jobs:
11
+ ci:
12
+ name: CI
13
+ runs-on: ubuntu-latest
14
+ steps:
15
+ - name: Checkout repository
16
+ uses: actions/checkout@v4
17
+
18
+ - name: Run CI
19
+ uses: ./.github/actions/ci
20
+ with:
21
+ turbo-token: ${{ secrets.TURBO_TOKEN }}
22
+ turbo-team: ${{ vars.TURBO_TEAM }}
@@ -0,0 +1,21 @@
1
+ name: PR Build
2
+
3
+ on:
4
+ pull_request: {}
5
+
6
+ env:
7
+ NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
8
+
9
+ jobs:
10
+ ci:
11
+ name: CI
12
+ runs-on: ubuntu-latest
13
+ steps:
14
+ - name: Checkout repository
15
+ uses: actions/checkout@v4
16
+
17
+ - name: Run CI
18
+ uses: ./.github/actions/ci
19
+ with:
20
+ turbo-token: ${{ secrets.TURBO_TOKEN }}
21
+ turbo-team: ${{ vars.TURBO_TEAM }}
@@ -0,0 +1 @@
1
+ 24.4.1
@@ -11,18 +11,18 @@
11
11
  "./schema": "./src/drizzle/schema/index.ts"
12
12
  },
13
13
  "scripts": {
14
- "build": "tsc -p tsconfig.json",
14
+ "typecheck": "tsc --noEmit",
15
15
  "db:generate": "drizzle-kit generate",
16
16
  "db:migrate": "drizzle-kit migrate"
17
17
  },
18
18
  "dependencies": {
19
- "@percepta/auth": "0.1.4",
19
+ "@percepta/auth": "^0.1.4",
20
20
  "drizzle-orm": "^0.45.2"
21
21
  },
22
22
  "devDependencies": {
23
+ "@percepta/build": "^1.0.0",
23
24
  "@types/node": "^24.1.0",
24
25
  "drizzle-kit": "^0.31.4",
25
- "tsx": "^4.20.3",
26
- "typescript": "^5.8.3"
26
+ "tsx": "^4.20.3"
27
27
  }
28
28
  }
@@ -5,7 +5,6 @@ import { sessions } from "./drizzle/schema/auth/sessions";
5
5
  import { verifications } from "./drizzle/schema/auth/verifications";
6
6
  import { users } from "./drizzle/schema/users";
7
7
 
8
- // eslint-disable-next-line n/no-process-env -- detecting Next.js build phase
9
8
  const isBuildPhase = process.env.NEXT_PHASE === "phase-production-build";
10
9
 
11
10
  function requiredEnv(name: string): string {
@@ -1,12 +1,3 @@
1
1
  {
2
- "extends": "../tsconfig.json",
3
- "compilerOptions": {
4
- "declaration": false,
5
- "declarationMap": false,
6
- "module": "ESNext",
7
- "moduleResolution": "Bundler",
8
- "noEmit": true,
9
- "types": ["node"]
10
- },
11
- "include": ["drizzle.config.ts", "src/**/*.ts"]
2
+ "extends": "@percepta/build/tsconfig/library"
12
3
  }
@@ -6,6 +6,7 @@ node_modules/
6
6
  dist/
7
7
  build/
8
8
  .turbo/
9
+ *.tsbuildinfo
9
10
 
10
11
  # IDE
11
12
  .idea/
@@ -0,0 +1,3 @@
1
+ import { defineOxfmtConfig } from "@percepta/build/oxfmt";
2
+
3
+ export default defineOxfmtConfig();
@@ -0,0 +1,3 @@
1
+ import { defineOxlintMonorepoConfig } from "@percepta/build/oxlint";
2
+
3
+ export default defineOxlintMonorepoConfig();
@@ -3,6 +3,7 @@
3
3
  "version": "0.0.1",
4
4
  "private": true,
5
5
  "description": "__APP_TITLE__",
6
+ "type": "module",
6
7
  "scripts": {
7
8
  "preinstall": "npx only-allow pnpm",
8
9
  "mosaic": "pnpm dlx __CREATE_PACKAGE__@__CREATE_VERSION__",
@@ -11,11 +12,12 @@
11
12
  "docker:down": "docker compose down",
12
13
  "db:setup-local": "node scripts/setup-local-databases.mjs",
13
14
  "dev": "pnpm -r --parallel --if-present run dev",
14
- "build": "pnpm -r --if-present run build",
15
- "clean": "pnpm -r --if-present run clean",
16
- "lint": "pnpm -r --parallel --no-bail --if-present run lint",
17
- "lint:fix": "pnpm -r --no-bail --if-present run lint:fix",
18
- "test": "pnpm -r --if-present run test",
15
+ "build": "turbo run build",
16
+ "clean": "turbo run clean",
17
+ "typecheck": "turbo run typecheck",
18
+ "lint": "oxlint",
19
+ "format": "oxfmt",
20
+ "test": "turbo run test",
19
21
  "access:merge": "percepta-access-control merge --apps-dir \"$PWD/packages\" --out-dir access",
20
22
  "access:validate": "percepta-access-control validate --apps-dir \"$PWD/packages\"",
21
23
  "access:apply": "pnpm run access:merge && percepta-access-control apply --schema access/merged.zed --applications access/applications.generated.json",
@@ -29,13 +31,19 @@
29
31
  },
30
32
  "engines": {
31
33
  "node": ">=20",
32
- "pnpm": ">=9"
34
+ "pnpm": ">=10"
33
35
  },
36
+ "packageManager": "pnpm@10.6.4",
34
37
  "devDependencies": {
35
- "@percepta/access-control": "0.8.0",
38
+ "@percepta/access-control": "^1.0.0",
39
+ "@percepta/build": "^1.0.0",
36
40
  "@types/node": "^24.1.0",
37
- "eslint": "^9.18.0",
41
+ "oxfmt": "^0.47.0",
42
+ "oxlint": "^1.61.0",
43
+ "oxlint-tsgolint": "^0.22.0",
38
44
  "rimraf": "^5.0.5",
39
- "typescript": "^5.8.3"
45
+ "tsdown": "^0.21.10",
46
+ "turbo": "^2.9.6",
47
+ "typescript": "^6.0.3"
40
48
  }
41
49
  }
@@ -0,0 +1,20 @@
1
+ {
2
+ "$schema": "https://turborepo.com/schema.json",
3
+ "ui": "tui",
4
+ "globalDependencies": ["pnpm-workspace.yaml"],
5
+ "tasks": {
6
+ "build": {
7
+ "dependsOn": ["^build"],
8
+ "outputs": ["dist/**", "**/.next/**", "!**/.next/cache/**"]
9
+ },
10
+ "typecheck": {
11
+ "dependsOn": ["^build"]
12
+ },
13
+ "test": {
14
+ "dependsOn": ["^build"]
15
+ },
16
+ "clean": {
17
+ "cache": false
18
+ }
19
+ }
20
+ }
@@ -1,2 +1 @@
1
1
  24.4.1
2
-
@@ -1,13 +1,14 @@
1
1
  # Webapp Template
2
2
 
3
- Next.js 15 full-stack application scaffolded from the Mosaic webapp template via `@percepta/create`. Uses React 19, TypeScript, Tailwind CSS v4, tRPC, Drizzle ORM, Better Auth, SpiceDB access control, and Inngest.
3
+ Next.js 16 full-stack application scaffolded from the Mosaic webapp template via `@percepta/create`. Uses React 19, TypeScript, Tailwind CSS v4, tRPC, Drizzle ORM, Better Auth, SpiceDB access control, and Inngest.
4
4
 
5
5
  ## Build & Dev Commands
6
6
 
7
7
  - `pnpm dev` — start dev server with Turbopack
8
8
  - `pnpm build` — production build
9
- - `pnpm lint` — run ESLint
9
+ - `pnpm typecheck` — type-check with `tsc`
10
10
  - `pnpm test` — run Vitest tests
11
+ - Linting and formatting run from the monorepo root: `pnpm lint` (oxlint) and `pnpm format` (oxfmt)
11
12
  - `pnpm access:validate` — validate access schema and manifest
12
13
  - `pnpm access:apply-local` — apply merged customer access schema to local SpiceDB
13
14
  - `pnpm auth:db:migrate` — run shared customer auth database migrations
@@ -25,9 +26,9 @@ If local LLM calls are needed, `pnpm dev` loads shared provider keys from `~/.co
25
26
  ## Code Style
26
27
 
27
28
  - Double quotes for strings
28
- - `no-console` is enforced use `@percepta/logger` instead (see below)
29
- - Logger messages must be plain string literals, not variables or templates
30
- - `no-process-env` is enforced — use `getEnvConfig()` from `src/config/`
29
+ - Prefer `@percepta/logger` over `console` (oxlint flags `console` as a warning, see below)
30
+ - Logger messages should be plain string literals, not variables or templates
31
+ - Read env via `getEnvConfig()` from `src/config/` rather than `process.env` directly (a project convention)
31
32
  - Use `@percepta/design` components before writing custom UI
32
33
  - For loading/error states, use local UI or add `@percepta/components` if you want `AsyncContent`
33
34
  - Tailwind CSS for all styling; icons from `lucide-react`
@@ -103,22 +104,26 @@ Also includes composite components: `ButtonWithDropdown`, `Combobox`, `IconButto
103
104
 
104
105
  ### @percepta/build — Shared Build Configs
105
106
 
106
- Provides centralized formatter, TypeScript, bundler, and Vitest configuration.
107
-
108
- ```js
109
- // eslint.config.mjs
110
- import eslint from "@eslint/js";
111
- import tseslint from "typescript-eslint";
112
-
113
- export default tseslint.config(eslint.configs.recommended, ...tseslint.configs.recommended);
114
- ```
107
+ Provides centralized linter (oxlint), formatter (oxfmt), TypeScript, bundler (tsdown), and Vitest configuration.
115
108
 
116
109
  ```json
117
110
  // tsconfig.json
118
111
  { "extends": "@percepta/build/tsconfig/web" }
119
112
  ```
120
113
 
121
- Vitest config is also available via `@percepta/build/vitest`.
114
+ ```ts
115
+ // oxfmt.config.ts
116
+ import { defineOxfmtReactConfig } from "@percepta/build/oxfmt";
117
+ export default defineOxfmtReactConfig({ stylesheet: "./src/styles/globals.css" });
118
+ ```
119
+
120
+ ```ts
121
+ // vitest.config.ts
122
+ import { createVitestConfig } from "@percepta/build/vitest";
123
+ export default createVitestConfig({ additionalSetupFiles: ["./vitest.setup.ts"] });
124
+ ```
125
+
126
+ Linting is configured once at the monorepo root via `@percepta/build/oxlint`.
122
127
 
123
128
  ### @percepta/components — Optional React Utilities
124
129
 
@@ -6,7 +6,7 @@ Design theme: `__MOSAIC_DESIGN_THEME__`
6
6
 
7
7
  ## Features
8
8
 
9
- - **Next.js 15** with App Router
9
+ - **Next.js 16** with App Router
10
10
  - **Authentication** via Better Auth with email/password credentials
11
11
  - **Database** with PostgreSQL, Drizzle ORM, and migrations
12
12
  - **Access Control** with SpiceDB schema authoring and manifest validation
@@ -87,7 +87,7 @@ src/
87
87
  | `pnpm dev` | Start development server with Turbopack |
88
88
  | `pnpm build` | Build for production |
89
89
  | `pnpm start` | Start production server |
90
- | `pnpm lint` | Run ESLint |
90
+ | `pnpm typecheck` | Type-check with `tsc` |
91
91
  | `pnpm access:validate` | Validate the access manifest and schema |
92
92
  | `pnpm access:apply-local` | Apply the merged customer access schema to local SpiceDB |
93
93
  | `pnpm auth:db:migrate` | Run migrations for the shared customer auth database |
@@ -0,0 +1 @@
1
+ declare module "*.css";
@@ -0,0 +1,5 @@
1
+ import { defineOxfmtReactConfig } from "@percepta/build/oxfmt";
2
+
3
+ export default defineOxfmtReactConfig({
4
+ stylesheet: "./src/styles/globals.css",
5
+ });
@@ -2,6 +2,7 @@
2
2
  "name": "__APP_NAME__",
3
3
  "version": "0.1.0",
4
4
  "private": true,
5
+ "type": "module",
5
6
  "engines": {
6
7
  "node": ">=18.0.0"
7
8
  },
@@ -9,7 +10,7 @@
9
10
  "dev": "tsx ./scripts/with-local-env.ts next dev --turbopack",
10
11
  "build": "next build",
11
12
  "start": "next start",
12
- "lint": "eslint .",
13
+ "typecheck": "tsc --noEmit",
13
14
  "setup": "pnpm --dir ../.. run setup",
14
15
  "access:validate": "percepta-access-control validate",
15
16
  "access:apply-local": "pnpm --dir ../.. run access:apply-local",
@@ -40,20 +41,20 @@
40
41
  "@grafana/faro-web-tracing": "^1.14.0",
41
42
  "@hookform/resolvers": "^5.2.2",
42
43
  "@mantine/hooks": "^8.3.1",
43
- "@next/env": "^15.3.5",
44
+ "@next/env": "^16.2.6",
44
45
  "@opentelemetry/api": "^1.9.0",
45
46
  "@opentelemetry/auto-instrumentations-node": "^0.75.0",
46
47
  "@opentelemetry/exporter-trace-otlp-proto": "^0.217.0",
47
48
  "@opentelemetry/sdk-node": "^0.217.0",
48
49
  "@__REPO_NAME__/auth": "workspace:*",
49
- "@percepta/access-control": "0.8.0",
50
- "@percepta/ai": "0.1.0",
51
- "@percepta/database": "0.1.2",
52
- "@percepta/design": "0.4.0",
53
- "@percepta/inngest": "0.1.0",
54
- "@percepta/logger": "0.1.0",
55
- "@percepta/next-utils": "0.2.1",
56
- "@percepta/utils": "0.1.10",
50
+ "@percepta/access-control": "^1.0.0",
51
+ "@percepta/ai": "^0.1.0",
52
+ "@percepta/database": "^0.1.2",
53
+ "@percepta/design": "^0.4.1",
54
+ "@percepta/inngest": "^0.1.0",
55
+ "@percepta/logger": "^0.1.0",
56
+ "@percepta/next-utils": "^0.2.2",
57
+ "@percepta/utils": "^0.1.11",
57
58
  "@radix-ui/react-slot": "^1.2.3",
58
59
  "@tanstack/react-query": "^5.81.5",
59
60
  "@tanstack/react-virtual": "^3.13.12",
@@ -73,7 +74,7 @@
73
74
  "lodash-es": "^4.17.21",
74
75
  "lucide-react": "^0.542.0",
75
76
  "mime-types": "^3.0.1",
76
- "next": "^15.3.5",
77
+ "next": "^16.2.6",
77
78
  "numeral": "^2.0.6",
78
79
  "pg": "^8.16.3",
79
80
  "pluralize": "^8.0.0",
@@ -92,10 +93,8 @@
92
93
  "zod": "^4.1.5"
93
94
  },
94
95
  "devDependencies": {
95
- "@eslint/js": "^9.18.0",
96
- "@next/eslint-plugin-next": "^15.3.5",
97
96
  "@playwright/test": "^1.58.2",
98
- "@percepta/build": "0.4.0",
97
+ "@percepta/build": "^1.0.0",
99
98
  "@tailwindcss/postcss": "^4.1.11",
100
99
  "@types/formidable": "^3.4.5",
101
100
  "@types/he": "^1.2.3",
@@ -109,16 +108,9 @@
109
108
  "@types/react-dom": "^19.0.3",
110
109
  "@types/yargs": "^17.0.33",
111
110
  "drizzle-kit": "^0.31.4",
112
- "eslint": "^9.18.0",
113
- "eslint-plugin-n": "^17.23.1",
114
- "eslint-plugin-react": "^7.37.4",
115
- "eslint-plugin-react-hooks": "^5.2.0",
116
- "globals": "^15.14.0",
117
111
  "husky": "^9.1.7",
118
112
  "tailwindcss": "^4.0.12",
119
- "typescript": "^5.7.3",
120
- "typescript-eslint": "^8.33.0",
121
- "vitest": "^3.2.1",
113
+ "vitest": "^4.0.0",
122
114
  "yargs": "^17.7.2"
123
115
  }
124
116
  }
@@ -49,7 +49,7 @@ const SEEDED_USERS = [
49
49
 
50
50
  async function main(): Promise<void> {
51
51
  nextEnv.loadEnvConfig(process.cwd());
52
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
52
+ // oxlint-disable-next-line typescript/no-explicit-any
53
53
  (globalThis as any).AsyncLocalStorage = AsyncLocalStorage;
54
54
 
55
55
  const { auth } = await import("@__REPO_NAME__/auth");
@@ -8,7 +8,7 @@ export default function GlobalError({
8
8
  reset: () => void;
9
9
  }) {
10
10
  try {
11
- // eslint-disable-next-line @typescript-eslint/no-require-imports
11
+ // oxlint-disable-next-line typescript/no-require-imports
12
12
  const { faro } = require("@grafana/faro-web-sdk");
13
13
  faro.api?.pushError(error);
14
14
  } catch {
@@ -1,5 +1,3 @@
1
- /* eslint-disable n/no-process-env */
2
-
3
1
  /**
4
2
  * Build-time development check. `NODE_ENV` is inlined by the bundler,
5
3
  * so this constant is safe to import in both server and client code.
@@ -6,9 +6,9 @@ import { getEnvConfig } from "../config/getEnvConfig";
6
6
  export const { client, db } = createDb();
7
7
 
8
8
  function createDb(): { client: Pool; db: NodePgDatabase } {
9
- const { DATABASE_URL: databaseUrl } = getEnvConfig();
9
+ const { DATABASE_URL: databaseUrl, NODE_ENV: nodeEnv } = getEnvConfig();
10
10
  const pool = createPgPool(
11
- readDatabaseConfig({ env: { DATABASE_URL: databaseUrl } }),
11
+ readDatabaseConfig({ env: { DATABASE_URL: databaseUrl, NODE_ENV: nodeEnv } }),
12
12
  );
13
13
 
14
14
  return { client: pool, db: drizzle(pool) };
@@ -1,6 +1,9 @@
1
+ import { BetterAuthClientOptions } from "better-auth";
1
2
  import { adminClient } from "better-auth/client/plugins";
2
3
  import { createAuthClient } from "better-auth/react";
3
4
 
4
- export const authClient = createAuthClient({
5
- plugins: [adminClient()],
6
- });
5
+ const adminPlugin: ReturnType<typeof adminClient> = adminClient();
6
+ const options = {
7
+ plugins: [adminPlugin],
8
+ } satisfies BetterAuthClientOptions;
9
+ export const authClient: ReturnType<typeof createAuthClient<typeof options>> = createAuthClient(options);
@@ -1,14 +1,3 @@
1
1
  {
2
- "extends": "@percepta/build/tsconfig/web",
3
- "compilerOptions": {
4
- "declaration": false,
5
- "declarationMap": false,
6
- "plugins": [{ "name": "next" }],
7
- "lib": ["dom", "dom.iterable", "esnext"],
8
- "allowJs": true,
9
- "noEmit": true,
10
- "isolatedModules": true,
11
- "jsx": "preserve"
12
- },
13
- "include": ["next-env.d.ts", ".next/types/**/*.ts", "**/*.ts", "**/*.tsx"]
2
+ "extends": "@percepta/build/tsconfig/web"
14
3
  }
@@ -1,9 +1,5 @@
1
- import { defineConfig } from "vitest/config";
1
+ import { createVitestConfig } from "@percepta/build/vitest";
2
2
 
3
- export default defineConfig({
4
- test: {
5
- environment: "node",
6
- include: ["src/**/__tests__/**/*.test.ts"],
7
- setupFiles: ["./vitest.setup.ts"],
8
- },
3
+ export default createVitestConfig({
4
+ additionalSetupFiles: ["./vitest.setup.ts"],
9
5
  });
@@ -1,10 +0,0 @@
1
- import eslint from "@eslint/js";
2
- import tseslint from "typescript-eslint";
3
-
4
- export default tseslint.config(
5
- eslint.configs.recommended,
6
- ...tseslint.configs.recommended,
7
- {
8
- ignores: ["node_modules/**", "dist/**"],
9
- }
10
- );
@@ -1,10 +0,0 @@
1
- import eslint from "@eslint/js";
2
- import tseslint from "typescript-eslint";
3
-
4
- export default tseslint.config(
5
- eslint.configs.recommended,
6
- ...tseslint.configs.recommended,
7
- {
8
- ignores: ["**/node_modules/**", "**/dist/**"],
9
- }
10
- );