fix: 7 ESLint errors blocking CI on fresh install (closes #47)#49
Merged
fix: 7 ESLint errors blocking CI on fresh install (closes #47)#49
Conversation
The CI gate (.github/workflows/deploy.yml) runs `pnpm run lint`, which fails on every push because of legitimately-flagged code patterns. None of these are real bugs — they're cases where the linter rule is correct in general but doesn't fit our specific intent. Fixed each at the smallest scope: - CookieBanner.svelte: privacyHref is operator-supplied (built from layout's `localePath()` → /[locale]/privacy-policy), not a build-time route — eslint-disable for svelte/no-navigation-without-resolve. - Seo.svelte: emit JSON-LD via concatenated string + escaped </script> sequence so untrusted JSON values can't break out; eslint-disable svelte/no-at-html-tags + drop the unnecessary `\/` escape. - webhooks/index.ts: drop the dead initializer on `responseExcerpt` (every code path reassigns before reading). - dashboard/+page.server.ts: drop unused `and` from drizzle-orm import. - media/+page.svelte: lookup map is local to a $derived block, rebuilt every invocation, never reactive — plain Map is correct; eslint-disable svelte/prefer-svelte-reactivity with rationale. - (www)/[locale]/[...slug]/+page.svelte: trusted server-rendered markdown — same eslint-disable pattern blog/[slug] already uses. After: `pnpm run lint` reports 0 errors (407 paraglide-generated prettier warnings remain — those are auto-generated and gitignored in spirit; separate cleanup). Build still green; svelte-check unchanged. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
thunpisit
added a commit
to codustry/khaopad-example
that referenced
this pull request
May 3, 2026
codustry#49 + PR codustry#50) (#15) Cherry-picks both upstream fixes: - PR codustry#49 (closes codustry#47) — 7 ESLint errors blocking CI on fresh install - PR codustry#50 (closes codustry#48) — switch articles_fts from contentless to external-content FTS5; UPDATE/DELETE on article_localizations no longer throws SQLITE_ERROR Migration 0011 already applied to live D1 (same database serves both repos). Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Closes #47. CI's gate job runs `pnpm run lint` which fails on every push due to 7 legitimately-flagged code patterns. None are real bugs — each fix scoped narrowly:
After:
```
✖ 407 problems (0 errors, 407 warnings)
```
407 warnings are all paraglide-generated files (gitignored in spirit) — separate cleanup.
Test plan
🤖 Generated with Claude Code