Difference between component types
Answered
Cuban Crocodile posted this in #help-forum
Cuban CrocodileOP
i was following the learn guide of next js and i have a brief idea of what different component are can someone affirm my beliefs
Client side components - you cant use event handling here
Server side components -
1 > static component - fetched once and a static file is created of the response wont make this again and again
2> dynamic component - fetches everytime doesnt cache anything.
Client side components - you cant use event handling here
Server side components -
1 > static component - fetched once and a static file is created of the response wont make this again and again
2> dynamic component - fetches everytime doesnt cache anything.
Answered by ᴉuɐpɹɐɐ
Client side components - you cant use event handling hereYou can, thats the whole point
Server side components -Dynamic component can also be cached but its cached at the data level, not the page level
1 > static component - fetched once and a static file is created of the response wont make this again and again
2> dynamic component - fetches everytime doesnt cache anything.
8 Replies
@Cuban Crocodile i was following the learn guide of next js and i have a brief idea of what different component are can someone affirm my beliefs
Client side components - you cant use event handling here
Server side components -
1 > static component - fetched once and a static file is created of the response wont make this again and again
2> dynamic component - fetches everytime doesnt cache anything.
Client side components - you cant use event handling hereYou can, thats the whole point
Server side components -Dynamic component can also be cached but its cached at the data level, not the page level
1 > static component - fetched once and a static file is created of the response wont make this again and again
2> dynamic component - fetches everytime doesnt cache anything.
Answer
@ᴉuɐpɹɐɐ > Client side components - you cant use event handling here
You can, thats the whole point
> Server side components -
> 1 > static component - fetched once and a static file is created of the response wont make this again and again
> 2> dynamic component - fetches everytime doesnt cache anything.
Dynamic component can also be cached but its cached at the data level, not the page level
Cuban CrocodileOP
but isnt that counter intuitive ? and only way to fix that is going to each function and doing noStore()
Cuban CrocodileOP
Dynamic component can also be cached but its cached at the data level, not the page level
this
data level meaning in fetchFunctions?
@Cuban Crocodile data level meaning in fetchFunctions?
Yes, and other non fetch function
Cuban CrocodileOP