Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 3 additions & 6 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,10 @@ jobs:

- uses: oven-sh/setup-bun@v2

- run: bun install
- run: bunx --package vite-plus@0.2.9 vp install --frozen-lockfile

- name: Lint
run: bun run lint

- name: Type check
run: bun run typecheck
- name: Check
run: bun run check

- name: Migration runner tests
run: bun test tests/scripts/db-migrate.test.ts
Expand Down
8 changes: 5 additions & 3 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ on:
branches: [main]
paths:
- ".github/workflows/deploy.yml"
- "bun.lock"
- "package.json"
- "apps/web/**"
- "apps/mcp-server/**"
- "db/migrations/**"
Expand All @@ -29,7 +31,7 @@ jobs:

- uses: oven-sh/setup-bun@v2

- run: bun install
- run: bunx --package vite-plus@0.2.9 vp install --frozen-lockfile

- name: Apply database migrations
run: bun run db:migrate
Expand All @@ -48,7 +50,7 @@ jobs:

- uses: oven-sh/setup-bun@v2

- run: bun install
- run: bunx --package vite-plus@0.2.9 vp install --frozen-lockfile

- name: Build
run: bun run build:prod
Expand All @@ -75,7 +77,7 @@ jobs:

- uses: oven-sh/setup-bun@v2

- run: bun install
- run: bunx --package vite-plus@0.2.9 vp install --frozen-lockfile

- name: Deploy MCP Server
uses: cloudflare/wrangler-action@v3
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ jobs:
with:
node-version: 24

- run: bun install
- run: bunx --package vite-plus@0.2.9 vp install --frozen-lockfile

- name: Create version pull request or release packages
uses: changesets/action@22ccf9aa43179fe9e27dc62e575971d28cce197c # v2.0.0
Expand Down
7 changes: 7 additions & 0 deletions .vite-hooks/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
if [ ! -x node_modules/.bin/vp ]; then
exit 0
fi

vp staged
Comment thread
caio-pizzol marked this conversation as resolved.
bun run typecheck
bun run build
5 changes: 5 additions & 0 deletions .vite-hooks/pre-push
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
if [ ! -x node_modules/.bin/vp ]; then
exit 0
fi

git fetch
Comment thread
caio-pizzol marked this conversation as resolved.
11 changes: 6 additions & 5 deletions CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,12 @@ dev/
## Commands

```bash
bun install # Install dependencies
bun dev # Web app at http://localhost:5173
bun dev:mcp # MCP server at http://localhost:8787
bun run build # Production build (web)
bun run typecheck # Type-check all packages
bunx --package vite-plus@0.2.9 vp install --frozen-lockfile # Install dependencies
bun dev # Web app at http://localhost:5173
bun dev:mcp # MCP server at http://localhost:8787
bun run check # Format, lint, and type-check
bun run build # Production build (web)
bun run typecheck # Type-check all packages
```

## Adding a Doc Page
Expand Down
12 changes: 8 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,12 +68,16 @@ Four tool families share one server:
## Development

```bash
bun install # Install dependencies
bun dev # Dev server at http://localhost:5173
bun run build # Production build
bun run build:prod # Build with the ignored .env.prod file
bunx --package vite-plus@0.2.9 vp install --frozen-lockfile # Install dependencies
bun dev # Dev server at http://localhost:5173
bun run check # Format, lint, and type-check
bun run build # Production build
bun run build:prod # Build with .env.prod
```

Vite+ owns the web development, build, formatting, linting, workspace task, and Git hook
workflows. Bun remains the package manager and test runtime because the test suite uses `bun:test`.

`build:prod` requires a live Clerk publishable key. This prevents production deploys from using the
auth fallback or a test Clerk instance.

Expand Down
2 changes: 1 addition & 1 deletion apps/mcp-server/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ Regenerate the bundled lookup from the pinned Annex D XML with `bun run mcp:pres

```bash
# Install (from repo root)
bun install
bunx --package vite-plus@0.2.9 vp install --frozen-lockfile

# Local dev — needs .dev.vars with DATABASE_URL and VOYAGE_API_KEY
bun run dev:mcp
Expand Down
2 changes: 1 addition & 1 deletion apps/mcp-server/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
},
"devDependencies": {
"@cloudflare/workers-types": "^4.20260127.0",
"typescript": "~5.9.3",
"typescript": "catalog:",
"wrangler": "^4.61.0"
}
}
2 changes: 1 addition & 1 deletion apps/mcp-server/src/ooxml-queries.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
* inheritance chains where it matters.
*/

// biome-ignore lint/suspicious/noExplicitAny: tagged-template sql differs between neon and postgres.
// oxlint-disable-next-line typescript/no-explicit-any -- Neon and Postgres expose different tagged-template types.
type Sql = any;

/**
Expand Down
2 changes: 1 addition & 1 deletion apps/mcp-server/src/ooxml-tools.ts
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ export function isOoxmlTool(name: string): name is OoxmlToolName {
return OOXML_TOOL_NAMES.has(name);
}

// biome-ignore lint/suspicious/noExplicitAny: neon's tagged template is loosely typed.
// oxlint-disable-next-line typescript/no-explicit-any -- Neon exposes a loosely typed tagged template.
type Sql = any;

/**
Expand Down
4 changes: 2 additions & 2 deletions apps/mcp-server/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"extends": "../../tsconfig.json",
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"noEmit": true,
"skipLibCheck": true,
"types": ["@cloudflare/workers-types"]
},
"include": ["src"]
Expand Down
13 changes: 7 additions & 6 deletions apps/web/package.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
{
"name": "@ooxml-dev/web",
"private": true,
"version": "1.3.0",
"private": true,
"type": "module",
"scripts": {
"dev": "vite",
"build": "tsc && vite build && bun scripts/prerender.ts",
"dev": "vp dev",
"build": "tsc --noEmit && vp build && bun scripts/prerender.ts",
"build:prod": "bun --env-file=${OOXML_PROD_ENV_FILE:-../../.env.prod} scripts/validate-production-env.ts && bun --env-file=${OOXML_PROD_ENV_FILE:-../../.env.prod} run build",
"preview": "vite preview",
"preview": "vp preview",
"typecheck": "tsc --noEmit",
"deploy": "bun run build:prod && wrangler pages deploy dist --project-name=ooxml-dev --branch=main --commit-dirty=true"
},
Expand All @@ -30,8 +30,9 @@
"@types/react-dom": "^19.2.3",
"@vitejs/plugin-react": "^5.1.2",
"tailwindcss": "^4.1.18",
"typescript": "~5.9.3",
"vite": "^7.3.1",
"typescript": "catalog:",
"vite": "catalog:",
"vite-plus": "catalog:",
"wrangler": "^4.61.0"
}
}
4 changes: 2 additions & 2 deletions apps/web/src/components/SearchDialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -98,13 +98,13 @@ export function SpecSearchDialog({ open, onOpenChange }: Props) {
}, [open]);

// Reset selection when search changes
// biome-ignore lint/correctness/useExhaustiveDependencies: intentionally reset when search changes
// oxlint-disable-next-line react/exhaustive-deps -- Reset only when the search changes.
useEffect(() => {
setSelectedIndex(0);
}, [search]);

// Scroll selected item into view
// biome-ignore lint/correctness/useExhaustiveDependencies: intentionally scroll when selectedIndex changes
// oxlint-disable-next-line react/exhaustive-deps -- Scroll only when the selection changes.
useEffect(() => {
if (resultsRef.current) {
const selected = resultsRef.current.querySelector("[data-selected='true']");
Expand Down
6 changes: 5 additions & 1 deletion apps/web/src/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,11 @@
}

body {
font-family: "Inter", system-ui, -apple-system, sans-serif;
font-family:
"Inter",
system-ui,
-apple-system,
sans-serif;
background-color: var(--color-bg-primary);
color: var(--color-text-primary);
margin: 0;
Expand Down
2 changes: 1 addition & 1 deletion apps/web/src/pages/SpecExplorer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ export function SpecExplorer() {
);

// Scroll selected item into view
// biome-ignore lint/correctness/useExhaustiveDependencies: intentionally scroll when selectedIndex changes
// oxlint-disable-next-line react/exhaustive-deps -- Scroll only when the selection changes.
useEffect(() => {
if (resultsRef.current) {
const selected = resultsRef.current.querySelector("[data-selected='true']");
Expand Down
7 changes: 3 additions & 4 deletions apps/web/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
{
"extends": "../../tsconfig.json",
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"baseUrl": ".",
"skipLibCheck": true,
"paths": {
"@/*": ["src/*"]
"@/*": ["./src/*"]
},
"types": ["node"],
"noEmit": true,
"jsx": "react-jsx"
},
"include": ["src", "vite.config.ts"]
Expand Down
4 changes: 2 additions & 2 deletions apps/web/vite.config.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { resolve } from "node:path";
import tailwindcss from "@tailwindcss/vite";
import react from "@vitejs/plugin-react";
import { defineConfig, loadEnv } from "vite";
import { defineConfig, loadEnv, lazyPlugins } from "vite-plus";

export default defineConfig(({ mode }) => {
const envKeys = ["VITE_CLERK_PUBLISHABLE_KEY", "CLERK_PUBLISHABLE_KEY"];
Expand All @@ -17,7 +17,7 @@ export default defineConfig(({ mode }) => {
"";

return {
plugins: [tailwindcss(), react()],
plugins: lazyPlugins(() => [tailwindcss(), react()]),
// The browser only receives Clerk's public key; secret keys remain server-only.
define: {
"import.meta.env.VITE_CLERK_PUBLISHABLE_KEY": JSON.stringify(clerkPublishableKey),
Expand Down
47 changes: 0 additions & 47 deletions biome.json

This file was deleted.

Loading