Skip to content

Commit 3e910ae

Browse files
DraftProductspi0
andauthored
fix(meta): add missing router.base prefix to favicon (#354)
* Relative path missing for the favicon The favicon must be accessible from any page and it does not matter how deep the page is. The only possible solution is to use a relative url. * Update module.js Co-authored-by: pooya parsa <[email protected]>
1 parent 8e05861 commit 3e910ae

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/meta/module.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ function generateMeta (pwa) {
111111
if (options.favicon && !find(this.options.head.link, 'rel', 'shortcut icon') && existsSync(favicon)) {
112112
console.warn('You are using a low quality icon, use icon png. See https://pwa.nuxtjs.org/icon/')
113113

114-
this.options.head.link.push({ rel: 'shortcut icon', href: 'favicon.ico' })
114+
this.options.head.link.push({ rel: 'shortcut icon', href: this.options.router.base + 'favicon.ico' })
115115
}
116116

117117
// Title

0 commit comments

Comments
 (0)