From 83476da97fe93442b9e57e8fa48d963807dc7865 Mon Sep 17 00:00:00 2001 From: Simon <10131203+gaomeng1900@users.noreply.github.com> Date: Sun, 12 Apr 2026 03:39:15 +0800 Subject: [PATCH] docs: update agents.md --- AGENTS.md | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index 8a0309e..093a91e 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -5,7 +5,7 @@ This is a **monorepo** with npm workspaces: - **Page Agent** (`packages/page-agent/`) - Main entry with built-in UI Panel, published as `page-agent` on npm -- **Extension** (`packages/extension/`) - Browser extension (WXT + React) 🚧 WIP +- **Extension** (`packages/extension/`) - Browser extension (WXT + React) - **Website** (`packages/website/`) - React docs and landing page. **When working on website, follow `packages/website/AGENTS.md`** Internal packages: @@ -18,10 +18,11 @@ Internal packages: ## Development Commands ```bash -npm start # Start website dev server -npm run build # Build all packages -npm run build:libs # Build all libraries -npm run lint # ESLint +npm start # Start website dev server +npm run build # Build all packages +npm run build:libs # Build all libraries +npm run typecheck # Typecheck all packages (libs + website + extension) +npm run lint # ESLint npm run zip -w @page-agent/ext # Zip the extension package ``` @@ -29,7 +30,7 @@ npm run zip -w @page-agent/ext # Zip the extension package ### Monorepo Structure -Simple monorepo solution: TypeScript references + Vite aliases. Update tsconfig and vite config when adding/removing packages. +Source-first monorepo: library `package.json` exports point to `src/*.ts` during development. At publish time, `scripts/pre-publish.js` promotes `publishConfig` fields to top-level (swapping to `dist/`), and `scripts/post-publish.js` restores the originals. ``` packages/