- When and why do we need
lazy()
? - What is
suspense
? - Why we got this
error
: A component was suspended while responding tosynchronous input
. This will cause theUI
to be replaced with aloading indicator
. Tofix this
,updates that suspend
should be wrapped withstart transition
? How doessuspense fix
this error? Advantages and Disadvantages
of using thiscode splitting pattern
?When
do we andwhy do we need suspense
?
- Create your
custom hooks
. - Try out
lazy and suspense
- Make your
code clean
.