1
0
mirror of https://github.com/amir20/dozzle.git synced 2025-12-30 17:47:28 +01:00

Tries to inline favicon to fix #1714 (#1717)

* Tries to inline favicon to fix #1714

* Updates go tests
This commit is contained in:
Amir Raminfar
2022-04-16 14:55:34 -07:00
committed by GitHub
parent 6434c5341a
commit ba32d125ac
4 changed files with 17 additions and 12 deletions

View File

@@ -11,7 +11,7 @@ export default defineConfig(({ mode }) => ({
"@/": `${path.resolve(__dirname, "assets")}/`,
},
},
base: mode === "production" ? "/<__BASE__>/" : "/",
base: mode === "production" ? "/{{ .Base }}/" : "/",
plugins: [
vue(),
Icons({
@@ -41,8 +41,9 @@ export default defineConfig(({ mode }) => ({
const htmlPlugin = (mode) => {
return {
name: "html-transform",
enforce: "post",
transformIndexHtml(html) {
return mode === "production" ? html.replaceAll("/<__BASE__>", "{{ .Base }}") : html;
return mode === "production" ? html.replaceAll("/{{ .Base }}/", "{{ .Base }}/") : html;
},
};
};