From be9298162bf4750d9965c1ac92ce7b09722d0399 Mon Sep 17 00:00:00 2001 From: Alex Date: Wed, 12 Jun 2024 13:38:22 +0800 Subject: [PATCH] docs: update work with WXT --- docs/help/faq.md | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/docs/help/faq.md b/docs/help/faq.md index 56b98874..63cd2eb6 100644 --- a/docs/help/faq.md +++ b/docs/help/faq.md @@ -79,3 +79,24 @@ export default defineConfig({ ], }) ``` + +## How to work with [WXT](https://wxt.dev/)? + +```ts +// wxt.config.ts +import { defineConfig } from 'wxt' +import vue from '@vitejs/plugin-vue' +import devtools from 'vite-plugin-vue-devtools' + +export default defineConfig({ + vite: () => ({ + plugins: [ + vue(), + devtools({ + // your app entrypoint (wherever you call createApp()) + appendTo: '/entrypoints/popup/main.ts', + }), + ], + }), +}) +```