mirror of
https://github.com/pbakaus/impeccable.git
synced 2026-09-15 15:46:30 +03:00
Fix browser script serving: run build after skill sync, serve via /js/
The skill sync wipes .claude/skills/ and re-copies from dist, deleting the generated browser script. Moved build-browser-detector.js to run AFTER the sync. Dev server's /js/* route now falls through to .claude/skills/critique/scripts/ for built artifacts. All fixture HTML references use /js/detect-antipatterns-browser.js (clean URL). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.6
parent
fbfe525f4f
commit
d8803c8151
+7
-7
@@ -322,13 +322,6 @@ async function build() {
|
||||
// Build CSS with Tailwind CLI (handles @theme directive)
|
||||
buildTailwindCSS();
|
||||
|
||||
// Generate browser anti-pattern detector from core module
|
||||
try {
|
||||
execSync('node scripts/build-browser-detector.js', { cwd: ROOT_DIR, stdio: 'inherit' });
|
||||
} catch (error) {
|
||||
console.error('Failed to build browser detector:', error.message);
|
||||
}
|
||||
|
||||
// Bundle HTML, JS, and compiled CSS with Bun
|
||||
await buildStaticSite();
|
||||
|
||||
@@ -395,6 +388,13 @@ async function build() {
|
||||
|
||||
console.log(`📋 Synced to .claude/: skills`);
|
||||
|
||||
// Generate browser anti-pattern detector (after skill sync so it doesn't get overwritten)
|
||||
try {
|
||||
execSync('node scripts/build-browser-detector.js', { cwd: ROOT_DIR, stdio: 'inherit' });
|
||||
} catch (error) {
|
||||
console.error('Failed to build browser detector:', error.message);
|
||||
}
|
||||
|
||||
console.log('\n✨ Build complete!');
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user