Comments (14)
Here's a way to reproduce this:
from react-scroll-parallax.
Please try v3.4.4 to see if this issue is resolved.
from react-scroll-parallax.
It's a react strict mode thing. If you turn off strict mode in dev then it works fine.
However that being said the code should be resilient to how react 18+ works so ideally the author can update the package to handle strict mode.
from react-scroll-parallax.
This should definitely be fixed in this library, also caused an issue for me in Nextjs 14
from react-scroll-parallax.
try v3.4.3
from react-scroll-parallax.
I now get Error: Could not find react-scroll-parallax
context value. Please ensure the component is wrapped in a
Whenever I save. Even though the wrapper is in the layout file.
I also see this error:
app-index.js:31 Warning: Cannot update a component (`HotReload`) while rendering a different component (`Parallax`). To locate the bad setState() call inside `Parallax`, follow the stack trace as described in https://reactjs.org/link/setstate-in-render
from react-scroll-parallax.
@raRaRa mind creating and sharing a minimal repo reproducing your setup? I'm unable to reproduce these hot reloading errors in my current setup - see repo here
from react-scroll-parallax.
I now get Error: Could not find
react-scroll-parallax
context value. Please ensure the component is wrapped in aWhenever I save. Even though the wrapper is in the layout file.
I upgraded to v3.4.3 and now the context value isn't there, even though I put around my app.
Just so you know, I'm using my own container ref.
from react-scroll-parallax.
I am also experiencing the issue:
Error: Could not find react-scroll-parallax
context value. Please ensure the component is wrapped in a
Using Next on version 3.4.3 of this package
from react-scroll-parallax.
If anyone can share a minimal repo that reproduces this error and clear steps to take for reproduction, that would be more helpful.
from react-scroll-parallax.
To reproduce, try editing page.tsx
and adding <AnimatedDiv />
's or editing page.tsx
in general. You should see that error come up. This also shows the issue with parallax effect just working initially, and then it stops. Maybe you can figure out what's going on, but I have a feeling that the library is not handling cases with strict mode, e.g. calling useEffects twice.
from react-scroll-parallax.
I have a PR that should fix these issues: #234
from react-scroll-parallax.
This issue appears to be resolved for me, running "react-scroll-parallax": "^3.4.4" and "next": "^14.0.3".
from react-scroll-parallax.
This issue appears to be resolved for me, running "react-scroll-parallax": "^3.4.4" and "next": "^14.0.3".
Same here, resolved using: "^3.4.4" and "next": "^14.0.3".
from react-scroll-parallax.
Related Issues (20)
- Making parallax move to end and back HOT 2
- Can't get an <a> tag to be clickable inside a layer HOT 1
- with react-custom-scrollbars HOT 1
- It always run onEnter at the beginning. HOT 1
- Mac OS - Scrolling only updates once you stop scrolling HOT 2
- Add `disabled` prop to `ParallaxProvider` HOT 1
- Not working with CRA or Create Next App HOT 3
- Stop the effect at a given position HOT 7
- Scrolling beyond a `scrollStart` or `scrollEnd` value does not update the affected property to final value HOT 1
- Styles not defined in documentation HOT 1
- Next Js 13.5 Effects are not being rendered HOT 16
- Update props of parallax element HOT 2
- Parallax effect not working in nextjs 13 HOT 6
- onLoad function does not fire on image layers HOT 1
- Could not find `react-scroll-parallax` context value. Please ensure the component is wrapped in a <ParallaxProvider> HOT 11
- Is it possible to animate custom properties? HOT 1
- Animation Position Issue with Sticky Container on Tab Change HOT 1
- Flickering when browser toolbar is shown/hidden HOT 2
- Can you do parallax and the image will remain fixed postion? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from react-scroll-parallax.