chenglou / chenglou/react-motion
Preact compatibility
- Dominant language
- JavaScript
- Stars
- 21.9k
- Forks
- 1.1k
- PR merge metrics
- No merged PRs in 30d
Description
I use abstraction over react-motion https://github.com/maisano/react-router-transition/ to control routing with react-router4 and encountered with optimization problem. In the React everything is fine, but with Preact (aliases preact/preact-compat in webpack) the route starts rendering a lot of times until animation finishes. By debugging I found that the problem in the TransitionMotion methods willEnter/willLeave which are responsible for the animation. Do not understand why the React and Preact handle these case in different ways.
btw, I tried to switch to preact-motion and the story is the same.
I don't know maybe it's Preact problem, well, if so, please let me know.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with the TransitionMotion methods willEnter and willLeave mentioned in the report, then reproduce the behavior through react-router-transition using the stated preact/preact-compat webpack aliases. Compare the React and Preact cases and determine whether repeated route rendering occurs during animation; document the cause or confirm the relevant compatibility issue.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, react, webpack
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100