feat(web): wire frontend to backend - #16
Merged
Merged
Conversation
🔍 Cora AI Code Review❌ Blocked — critical issues found. 🔴 Error (3)
Review powered by cora-cli · BYOK · MIT |
- Rewrite api.ts: correct routes matching Axum backend, env-based config,
auto-unwrap { data: ... } wrapper from all responses
- Rewrite types.ts: match actual Rust model field names (not ERD)
- Fix vite.config.ts: remove invalid polyfillNode, proxy /api and /health
to localhost:7845 (backend has /api prefix, no rewrite needed)
- Fix api.ts getApiKey: read from localStorage at call-time (not module load)
with VITE_API_KEY env fallback for dev
- Fix all pages: remove res.data unwrapping, update field names
(expires_at, error, caption flat), remove unused cancel/complete buttons
- Fix StatusBadge: rename maptVariant -> mapToVariant, add status mappings
- Comments page: rewrite to use per-post comment routes
- adapter-node replaces adapter-auto
Verified: bun run check 0 errors, bun run build clean, all 7 pages
load without JS errors against running backend via Vite proxy.
ajianaz
force-pushed
the
feat/wire-frontend-backend
branch
from
July 22, 2026 15:20
a8430aa to
9895e76
Compare
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.
What
Wire the SvelteKit admin dashboard to the actual Titen API backend.
Changes
/api→localhost:7845,/health→localhost:7845(no prefix rewriting needed — backend routes already match){ data: ... }wrapper from all backend responsesaccounts:token_expires_at→expires_atschedules: flat fields (nopost_datawrapper), removed cancel/complete (backend update is delete+recreate)analytics: added missingtrend/trendMaxstate, disabled per-post trend (endpoint is per-post, not per-account)comments: rewritten to load comments per-post (no list-all endpoint exists)posts,dashboard,settings,media: minor field name fixesok/valid/unknownmappings, fixed typomaptVariant→mapToVariantVerification
bun run check— 0 errors, 15 warnings (all pre-existing)bun run build— passesFollow-up