scaleflex / react-cloudimage-responsive

Cloudimage Responsive will smartly resize, compress and accelerate images across the World in your site for all devices. The plugin supports lazy loading technique with fancy animation on image load. Any questions or issues, please report to https://github.com/scaleflex/react-cloudimage-responsive/issues
MIT License
45 stars 16 forks source link

Problem with plugin install #11

Closed laurage closed 4 years ago

laurage commented 4 years ago

Hello,

I have just installed react-cloudimage-responsive with npm but I get this error:

client.js:196 ./node_modules/react-cloudimage-responsive/dist/polyfills.jsModule not found: Error: Can't resolve 'core-js/es/math/trunc' in '/Users/me/Documents/code/projects/sanity-gatsby-portfolio/web/node_modules/react-cloudimage-responsive/dist'./node_modules/react-cloudimage-responsive/dist/polyfills.jsModule not found: Error: Can't resolve 'core-js/features/array/find' in '/Users/me/Documents/code/projects/sanity-gatsby-portfolio/web/node_modules/react-cloudimage-responsive/dist'./node_modules/react-cloudimage-responsive/dist/polyfills.jsModule not found: Error: Can't resolve 'core-js/features/array/for-each' in '/Users/me/Documents/code/projects/sanity-gatsby-portfolio/web/node_modules/react-cloudimage-responsive/dist'

This is what I got from the terminal upon install: `

core-js@3.6.4 postinstall /Users/me/Documents/code/projects/sanity-gatsby-portfolio/web/node_modules/react-cloudimage-responsive/node_modules/core-js node -e "try{require('./postinstall')}catch(e){}"

I am using React 16.8.6.

Any idea of how to solve this? Thanks!

dzmitry-stramavus commented 4 years ago

hey @laurage ,

try to install npm i core-js manually.

It should be installed automatically

laurage commented 4 years ago

Hi, I thought this solved my problem for a minute but it didn't, I still get the same error. I tried with the latest core-js version (3.6.4) and also the one I think you use (3.0.0), no success. Any other idea?

dzmitry-stramavus commented 4 years ago

ok, try to remove node_modules and package-lock.json. And run npm install

laurage commented 4 years ago

Hello, Sadly it's still bringing the same errors when doing this.

dzmitry-stramavus commented 4 years ago

I'm closing the issue since nobody can reproduce the problem