What problem does it solve?
When rebuilding a Vite React application, code changes fail to appear in the browser even after clearing the cache, as Nginx serves stale cached JavaScript files with immutable cache headers, causing wasted debugging time and incorrect production behavior.
Core Features & Use Cases
- Stale Cache Diagnosis: Verify if Nginx is serving outdated files by checking dist file modification times, HTTP cache headers (ETag, Cache-Control), and whether file content matches your latest code.
- Permanent Fix: Configure Vite to add content hashes to output filenames so Nginx's immutable caching works correctly without serving stale files.
- Temporary Fix: Disable Nginx's immutable caching headers to force fresh file serving during urgent deployments.
- Use Case: Frontend developers and DevOps engineers deploying Vite-powered React apps to Nginx who encounter persistent stale code issues after rebuilds.
Quick Start
Ask the AI to diagnose and fix stale cache issues when your rebuilt Vite React app does not show recent code changes on an Nginx server.