mirror of
https://github.com/transloadit/uppy.git
synced 2026-07-18 00:55:35 +00:00
update vite.config.ts
This commit is contained in:
parent
a377fe9039
commit
72346aec58
1 changed files with 7 additions and 0 deletions
|
|
@ -6,4 +6,11 @@ import { defineConfig } from 'vite'
|
|||
// https://vitejs.dev/config/
|
||||
export default defineConfig({
|
||||
plugins: [react(), tailwindcss()],
|
||||
// @vitejs/plugin-react v5+ no longer adds react/react-dom to resolve.dedupe
|
||||
// automatically (it did in v4). Without deduping, the linked @uppy/react
|
||||
// workspace pulls in a second React copy, causing "Invalid hook call".
|
||||
// https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react/CHANGELOG.md (v5.0.0)
|
||||
resolve: {
|
||||
dedupe: ['react', 'react-dom'],
|
||||
},
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue