diff --git a/README.md b/README.md index f5be45d..6b84766 100644 --- a/README.md +++ b/README.md @@ -22,7 +22,6 @@ npm install vite-svg-loader --save-dev ### Setup #### `vite.config.js` - ```js import svgLoader from 'vite-svg-loader' @@ -30,3 +29,15 @@ export default { plugins: [vue(), svgLoader()] } ``` + +### Use with TypeScript +If you'd like to use the loader in a TypeScript project, you'll need to add the following type definition to your `tsconfig.json` file: + +#### `tsconfig.json` +```json +{ + "compilerOptions": { + "types": ["vite-svg-loader", "vite/client"] + } +} +```