Replies: 2 comments
-
I can solve my problem with: const navigation = useNavigation()
if (navigation.state === 'loading') {
// Do not do the thing with params
} else {
// Do the things with params
} |
Beta Was this translation helpful? Give feedback.
0 replies
-
I'm also encountering this issue. It's causing some visual issues since many of the components use Framer motion, and they are re-animating prior to navigating. It seems heavy-handed to memoize every component. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
It seems that Remix re-renders the current React component when a
Link
is clicked. I don't mind the re-render, it's not a perf issue, but in my case it's causingconst params = useParams()
to be same on the new page, which causes problems.I think this thread on react-router repo is about the same thing.
Beta Was this translation helpful? Give feedback.
All reactions