AI Coding

Working on this template with an assistant

The template ships an AGENTS.md at its root. Point your assistant at it once and it will know the conventions — and, more usefully, the handful of things here that look correct and are not.

1. Point the tool at AGENTS.md

One file, not one per tool. .cursorrules, CLAUDE.md and the rest drift apart the moment someone edits only one of them, and a stale rule file is worse than none.

ToolWhat to do
Claude CodePicked up automatically, or @AGENTS.md
Cursorecho "See AGENTS.md" > .cursorrules
GitHub CopilotPoint .github/copilot-instructions.md at it
Windsurf, Cline, AiderAttach it, or /read AGENTS.md
Anything elsePaste it into the first message

2. The one thing to say in every prompt

The HTML pages (dashboards/, apps/ …) are the source: edit them directly. What an assistant most often gets wrong is the design system — raw colours, a hand-written dark variant, a plugin stylesheet that overrides the theme.

Read AGENTS.md first. Use only tokens from tokens.css,
copy markup from the existing pages, then run
npm run build and npm run lint and tell me if either fails.

AGENTS.md has the table of which file holds what.

3. Prompts that work

Each of these names the file, the constraint and how to check the result.

A new page

Add a "Reports" page as apps/reports.html, copied from blank.html.
Follow the card markup in AGENTS.md section 6, add it to the
sidebar on every page, use only tokens from tokens.css, then
run npm run build and tell me if it fails.

A new dashboard

Add a Logistics dashboard as dashboards/logistics.html.
Copy the structure of an existing dashboard (KPI cards, chart
cards, a table), add it to the sidebar on every page, keep the
chart data in the page's JSON blocks. Run npm run build.

A theming change

Change the warning colour. Edit --color-warning in
tokens.css only. Do not touch the primary ramp, and do not
replace status colours with palette colours.

A plugin

Add <plugin>. Register it in core/plugins.js behind a
marker attribute so it only loads on pages that use it, and
import its stylesheet through a wrapper in
assets/css/vendor/ with layer(vendor) — otherwise it will
override the theme.

4. Ask it to check its own work

A build passing is not the same as the page looking right. Several bugs in this template's own history — a tab that went black-on-black when hovered, a chart that rendered on a grey panel, a right-to-left corner mirrored only halfway — compiled cleanly and were visible only on screen.

After the change, run npm run build. Then either show me
a screenshot or read the computed styles back from a headless
browser. Do not report a visual change as done on a passing
build alone.

If your tool can drive a browser, that is the stronger option. If it cannot, look at the page yourself before accepting the change.

5. What to refuse

Assistants are obliging by default. These are worth stating up front, because the cost of each is paid later:

  • Adding a framework or a second styling system to solve a one-page problem.
  • Reaching for !important instead of finding why a rule lost.
  • Writing raw colours into a page instead of adding a token.
  • Inventing people, companies, logos or testimonials for demo content.
  • Describing the sign-in pages as working authentication. They are presentation only.

6. Honest limits

An assistant reading AGENTS.md starts better informed than one that is not. It does not make it right. Two habits are worth keeping:

  • Work in small commits, so a bad change is one git revert away.
  • Read the diff. A long page diff is easy to skim, and a confident explanation is not evidence the output is correct.

The trap list in AGENTS.md exists because every item on it was shipped wrong at least once first.