diff --git a/README.md b/README.md index c3dc4db..afc55c4 100644 --- a/README.md +++ b/README.md @@ -213,7 +213,7 @@ function __getWebviewHtml__( | --- | --- | --- | --- | | recommended | `boolean` | `true` | This option is intended to provide recommended default parameters and behavior. | | extension | [ExtensionOptions](#ExtensionOptions) | | Configuration options for the vscode extension. | -| webview | `boolean` | `false` | Inject [@tomjs/vscode-extension-webview](https://github.com/tomjs/vscode-extension-webview) into vscode extension code and web client code, so that webview can support HMR during the development stage. | +| webview | `boolean` \| `string` \| [WebviewOption](#WebviewOption) | `__getWebviewHtml__` | Inject html code | **Notice** @@ -222,6 +222,16 @@ The `recommended` option is used to set the default configuration and behavior, - The output directory is based on the `build.outDir` parameter of `vite`, and outputs `extension` and `src` to `dist/extension` and `dist/webview` respectively. - Other behaviors to be implemented +**Webview** + +Inject [@tomjs/vscode-extension-webview](https://github.com/tomjs/vscode-extension-webview) into vscode extension code and web client code, so that `webview` can support `HMR` during the development stage. + +- vite serve + - extension: Inject `import __getWebviewHtml__ from '@tomjs/vscode-extension-webview';` above the file that calls the `__getWebviewHtml__` method + - web: Add `