简体   繁体   中英

Run https://github.com/akella/webgl-mouseover-effects code locally

I want to implement image hover effect like on this website https://miew.pt/ , and the closest example I got or came across can be found here https://github.com/akella/webgl-mouseover-effects

  1. I have downloaded and extracted the files but when I run/open eg step3.html, I am getting errors.

  2. I have run yarn add but still getting same error as in point 1.

The error in point 1 & 2 is "Uncaught SyntaxError: Cannot use import statement outside a module"

What's the correct way to set up the code locally(Win 10)?

I just used:

npm install
npm run parcel -- step3.html

and it worked on my setup (Win 10 + NPM 6.14.14 + Node v14.17.5)

Can you try again with this setup ?

在此处输入图像描述

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM