the <div id=root> was empty until the JS bundle downloaded and React mounted, so the page was blank for ~2.4s (FCP). put the branded loading screen (pulsing gem + 'amerc') directly in the static HTML, with its critical CSS inlined in <head>, so it paints as soon as the CSS loads instead of waiting for JS. - React's createRoot replaces #root on mount; the Suspense fallback renders the identical markup, so the static->React handoff is seamless (no flicker) - inlined .app-loading critical CSS mirrors styles.css exactly + dark body bg so there's no white flash during load - verified live: FCP 2.4s -> 1.4s, performance 86 -> 90, TBT 50 -> 0ms; app mounts cleanly, static loader replaced, 0 console errors
19 lines
386 B
JSON
19 lines
386 B
JSON
{
|
|
"name": "amerc-site",
|
|
"version": "0.85.0-fastpaint",
|
|
"private": true,
|
|
"type": "module",
|
|
"scripts": {
|
|
"dev": "vite --host 0.0.0.0",
|
|
"build": "vite build",
|
|
"preview": "vite preview --host 0.0.0.0"
|
|
},
|
|
"dependencies": {
|
|
"@vitejs/plugin-react": "^5.0.0",
|
|
"marked": "^14.1.4",
|
|
"react": "^19.0.0",
|
|
"react-dom": "^19.0.0",
|
|
"vite": "^7.0.0"
|
|
}
|
|
}
|