web3-react
web3-react copied to clipboard
Package @web-react/gnosis-safe does not bundle with Vite 4 in production
Hello, I am using the @web3-react/gnosis-safe package with which works with Vite in development, but in production mode there Vite can't relate/find to the packages libraries:
- @safe-{}/safe-apps-provider
- @safe-{}/safe-apps-sdk
The warning message from Vite in production:
- "@safe-{}/safe-apps-provider" is imported by "@safe-{}/safe-apps-provider?commonjs-external", but could not be resolved – treating it as an external dependenc
- "@safe-{}/safe-apps-sdk" is imported by "@safe-{}/safe-apps-sdk?commonjs-external", but could not be resolved – treating it as an external dependency.
The dapp in development mode runs without issues in productions the dapp does not work as it cannot find correctly the two packages.
Tried to use commonjs() plugin for Vite but no luck, do you have any suggestions?