fix(favicon): show dedicated icon on 404 pages

Add favicon-404.ico and switch tab favicon on not-found routes while
keeping static app pages and larger crawler icons unchanged.
This commit is contained in:
Tommaso Casaburi
2026-06-27 17:38:55 +07:00
parent eacb422f40
commit f213d41296
7 changed files with 61 additions and 14 deletions
+3 -1
View File
@@ -39,6 +39,7 @@ const neverPrecacheUrls = new Set(['index.html', 'version.json']);
const vitePwaManagedAssetUrls = new Set([
'manifest.webmanifest',
'favicon.ico',
'favicon-404.ico',
'favicon2.ico',
'robots.txt',
'apple-touch-icon.png',
@@ -50,6 +51,7 @@ const baselineAppShellUrls = new Set([
'manifest.json',
'manifest.webmanifest',
'favicon.ico',
'favicon-404.ico',
'favicon2.ico',
'robots.txt',
'apple-touch-icon.png',
@@ -393,7 +395,7 @@ export default defineConfig({
enabled: true,
type: 'module',
},
includeAssets: ['favicon.ico', 'favicon2.ico', 'robots.txt', 'apple-touch-icon.png'],
includeAssets: ['favicon.ico', 'favicon-404.ico', 'favicon2.ico', 'robots.txt', 'apple-touch-icon.png'],
manifest: {
name: '5chan',
short_name: '5chan',