kv-netflix/frontend-react/index.html

41 lines
No EOL
1.3 KiB
HTML

<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="/vite.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>kv-netflix</title>
<meta name="theme-color" content="#141414" />
<meta name="description" content="Modern Movie Streaming Service" />
<link rel="apple-touch-icon" href="/icon.png" />
<script>
// IMMEDIATE CLEANUP: Unregister all service workers and clear caches in development
if (window.location.hostname === 'localhost' || window.location.hostname === '127.0.0.1') {
if ('serviceWorker' in navigator) {
navigator.serviceWorker.getRegistrations().then(registrations => {
if (registrations.length > 0) {
Promise.all(registrations.map(r => r.unregister())).then(() => {
console.log('Unregistered SWs');
window.location.reload();
});
}
});
}
if (window.caches) {
caches.keys().then(names => {
Promise.all(names.map(name => caches.delete(name))).then(() => {
if (names.length > 0) console.log('Cleared Caches');
});
});
}
}
</script>
</head>
<body>
<div id="root"></div>
<script type="module" src="/src/main.tsx"></script>
</body>
</html>