Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot use import statement outside a module #3

Open
gr-akshaya opened this issue Jul 25, 2023 · 1 comment
Open

Cannot use import statement outside a module #3

gr-akshaya opened this issue Jul 25, 2023 · 1 comment

Comments

@gr-akshaya
Copy link

While using phantom wagmi connector, getting error that cannot use import statement outside a module.

.......node_modules\phantom-wagmi-connector\dist\index.js:1
import { ConnectorNotFoundError, InjectedConnector, } from "@wagmi/core";
^^^^^^

SyntaxError: Cannot use import statement outside a module

@arguiot
Copy link

arguiot commented May 29, 2024

In your next config, add it to the transpiled packages:

const nextConfig = {
 // ... your config
  transpilePackages: ['phantom-wagmi-connector'],
};

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants
@arguiot @gr-akshaya and others