Skip to content

Commit

Permalink
docs: add a workaround to isolatedModules: true (#4286)
Browse files Browse the repository at this point in the history
  • Loading branch information
fwouts committed Oct 21, 2021
1 parent 7e25429 commit ea0c221
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions docs/guide/features.md
Expand Up @@ -66,6 +66,8 @@ But a few libraries haven't transitioned to this new default yet, including [`li
- [`jsxFactory`](https://www.typescriptlang.org/tsconfig#jsxFactory)
- [`jsxFragmentFactory`](https://www.typescriptlang.org/tsconfig#jsxFragmentFactory)

If migrating your codebase to `"isolatedModules": true` is an unsurmountable effort, you may be able to get around it with a third-party plugin such as [rollup-plugin-friendly-type-imports](https://www.npmjs.com/package/rollup-plugin-friendly-type-imports). However, this approach is not officially supported by Vite.

### Client Types

Vite's default types are for its Node.js API. To shim the environment of client side code in a Vite application, add a `d.ts` declaration file:
Expand Down

0 comments on commit ea0c221

Please sign in to comment.