diff --git a/agents-docs/LESSONS.md b/agents-docs/LESSONS.md index ca2f51e..506e8c5 100644 --- a/agents-docs/LESSONS.md +++ b/agents-docs/LESSONS.md @@ -102,6 +102,13 @@ Durable rules for AI agents working on this project. Read this file at session s - **Why:** `npm run test` only runs the toju-app Vitest suite — it doesn't cover the server, Electron, or website packages. ESLint (flat config in `eslint.config.js`) is the universal check across every package; type-style violations slip through tests and break Gitea Workflows for the next agent. - **Example:** `npm run lint && echo OK` — only claim done after seeing `OK`. For Electron type errors specifically, also confirm `npm run build:electron` succeeds (it invokes `tsc -p tsconfig.electron.json`). +### Use blob URLs for inline attachment previews [attachments] [electron] + +- **Trigger:** receiving users see broken image icons or video players that never start, but "Download" saves a valid file. +- **Rule:** never bind `attachment.objectUrl` to `file://` URLs for chat ``, `