useServerFn

A POST from a click, then the loader runs again

The list below is loaded by listNotes() during render. Submit calls addNote() through useServerFn, which is the hook for calling a server function from an event. After the POST resolves, router.invalidate() runs the loader again, so the new note is read from the server rather than appended only in the browser.

No client call yet.

All examples