B
B
Black back2020-12-30 10:56:31
JavaScript
Black back, 2020-12-30 10:56:31

How to do asynchronous page replacement in react js?

Hello, I'm starting to learn react js. And here I have a problem. I have a page with 2 buttons. I need when a button is clicked, the page changes to another asynchronously. That is, the buttons should disappear. What to use? What to read? Sorry if that, I'm just a beginner)

Answer the question

In order to leave comments, you need to log in

2 answer(s)
N
n1ksON, 2020-12-30
@n1ksON

Read about props, react-router and hooks, in particular useState and useEffect.

S
Sergey Melnikov, 2020-12-30
@mlnkv

https://codesandbox.io/s/goofy-https-xeyhv?file=/s...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question