Usage for React & Nextjs
ChetSocio opened this issue · comments
Description of the problem
I am trying to use it for client's ecommerce but if I try to use only hover , then i always get "failed to execute removeChild" error. Always get this error just because I don't want to use other options but only hover? Why havenot you provided documentation for single option usage among hover, click, cursor, etc ??? Send me screenshot or stackblitz link where you have created only zoom on hover.
I want to make sure my customers don't have to click buttons everytime they try to zoom image using hover. Make it simple like react-image-zoom package or tell me how i can achieve zoom on hover by default using this package and need not to show other options on my page.
Dear @ChetSocio,
I am so sorry for the inconvenience. I never intended to force library users to click a button before activating the feature. You probably used the version of Reacrt 18 or so which caused the useEffect hook to run twice during development mode, it still works fine in production though. I just included the fix in #205. It should fix the issue now, please update your dependency to the latest. Here is the demo on Stackblitz - https://stackblitz.com/edit/willnguyen1312-zoom-image-vxbn53?file=package.json
![image](https://private-user-images.githubusercontent.com/17794897/271309172-6e016317-d5c1-4936-b67f-f47ae5baa584.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjA2Njg1NzYsIm5iZiI6MTcyMDY2ODI3NiwicGF0aCI6Ii8xNzc5NDg5Ny8yNzEzMDkxNzItNmUwMTYzMTctZDVjMS00OTM2LWI2N2YtZjQ3YWU1YmFhNTg0LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA3MTElMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNzExVDAzMjQzNlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWMxYzhkMDljMWFmZTA5NTAzMjgxYWNlZmVjMjA1Mjk4YTk0ZDFjZGQ3MTU5ODUxMWFiZGE5NjQ5MjE5N2Q3MmEmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.7xXtUpxIpyVV7ENa9U0iRrwqbaPYqHXcvUyXAAnxZIQ)
Please let me know how it goes on your end and whether you need extra support from me
Thanks so much :)
Best,
Nam
I think it's the problem with the package manager caching mechanism. You can try to clear it and install the latest one from npm. Thanks 🙂