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

Next.js - SyntaxError: Invalid or unexpected token #212

Open
sergei97k opened this issue Apr 25, 2022 · 8 comments
Open

Next.js - SyntaxError: Invalid or unexpected token #212

sergei97k opened this issue Apr 25, 2022 · 8 comments

Comments

@sergei97k
Copy link

Hi,

I have an issue with Next.js + useWallet setup. The error is next:

Снимок экрана 2022-04-25 в 18 07 45

My package.json file:

{
 "dependencies": {
    "next": "12.1.5",
    "react": "18.0.0",
    "react-dom": "18.0.0",
    "use-wallet": "0.13.6"
  },
}

As I managed to find out that the problem is in the pictures. I have downgraded to several previous versions. You can see the difference in the following links:

As I see from your commits, it was in these versions that pictures were added to the repository. I think this could be the reason.

Please, can you recommend something that I can do with it? Do I need the additional setup for Next.js to resolve it?

@tripplyons
Copy link

I'm running into this same issue with the latest version, and was able to resolve the issue by using the older version you suggested (0.13.4) by running npm i -s [email protected].

@albsa
Copy link

albsa commented Jun 13, 2022

It has something to do with the Png file /use-wallet/dist/cjs/Cipher.png:1

@billyjacoby
Copy link

I'm having the same issue as discussed here

@iquirino
Copy link

iquirino commented Aug 4, 2022

+1

@iquirino
Copy link

iquirino commented Aug 4, 2022

mathewmeconry introduced assets of wallet connectors.
the better path to solve this issue is to rollback these images.
wallet vendor images are out of the responsibility of this hook and could be easily implemented by the user.

@albsa
Copy link

albsa commented Aug 4, 2022

@iquirino i forked the latest version, removed the images and fixed the metamask issue with the missing argument.
feel free to check it out https://www.npmjs.com/package/@albs1/use-wallet or fork it yourself with the changes.

@iquirino
Copy link

iquirino commented Aug 4, 2022

@iquirino i forked the latest version, removed the images and fixed the metamask issue with the missing argument. feel free to check it out https://www.npmjs.com/package/@albs1/use-wallet or fork it yourself with the changes.

Have you opened a new PR to @bpierre evaluate it to the official package?

@iquirino
Copy link

iquirino commented Aug 5, 2022

New PR to solve this issue: #229

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

5 participants