Move generated browser script to .claude/skills/critique/scripts/

The generated browser detector now lives alongside the CLI script in
.claude/skills/critique/scripts/ — clearly a build artifact, not a
hand-maintained source file in public/js/.

- build-browser-detector.js outputs to .claude/ instead of public/js/
- Dev server serves .claude/skills/* for local testing
- All fixture and antipattern-example HTML files updated to new path
- Puppeteer detectUrl reads browser script from same directory
- Browser parity test server updated to serve from .claude/
- Deleted public/js/detect-antipatterns-browser.js

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Paul Bakaus
2026-03-17 18:11:35 -07:00
co-authored by Claude Opus 4.6
parent 623a8a8375
commit fbfe525f4f
28 changed files with 42 additions and 650 deletions
@@ -480,9 +480,10 @@ async function detectUrl(url) {
}
// Read the browser detection script — reuse it instead of reimplementing
// The generated browser script lives alongside this file after build
const browserScriptPath = path.resolve(
path.dirname(new URL(import.meta.url).pathname),
'..', '..', '..', '..', 'public', 'js', 'detect-antipatterns-browser.js'
'detect-antipatterns-browser.js'
);
let browserScript;
try {