-
Notifications
You must be signed in to change notification settings - Fork 3
/
wxt.config.ts
44 lines (43 loc) · 1.1 KB
/
wxt.config.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
import { defineConfig } from "wxt";
import Icons from "unplugin-icons/vite";
export default defineConfig({
srcDir: "src",
extensionApi: "chrome",
experimental: {
entrypointImporter: "vite-node",
},
modules: [
"@wxt-dev/module-vue",
"@wxt-dev/i18n/module",
"@wxt-dev/auto-icons",
],
imports: {
presets: ["vue-router"],
imports: [
{ from: "@tanstack/vue-query", name: "useQuery" },
{ from: "@tanstack/vue-query", name: "useMutation" },
],
},
vite: () => ({
plugins: [Icons({ compiler: "vue3" })],
ssr: {
// List any dependencies that depend on webextension-polyfill here for vite-node importer to work
noExternal: ["@webext-core/proxy-service", "@webext-core/messaging"],
},
}),
manifest: ({ browser }) => {
const permissions = ["storage"];
if (browser === "firefox") {
permissions.push("https://api.github.com/*");
}
return {
default_locale: "en",
name: "__MSG_name__",
description: "__MSG_description__",
permissions,
};
},
autoIcons: {
grayscaleOnDevelopment: false,
},
});