Comment

Comment by slooonz

I find the data fetching example extremely confusing…

1. Where does this "use" comes from ? It is not present in the official React API reference : https://reactjs.org/docs/react-api.html

2. It says that the value is not serialized, but what if Page is rendered client side and I want getData to always be executed server side (for example, it may contains secret API key, or make a database call) ?

3. getData is async, so what happens to name if the promise is not yet resolved ?

parent slooonz 4 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton