docs: adding missing params

This commit is contained in:
Saeid Zareie 2025-01-16 08:23:43 +03:30
parent 0c845bed5a
commit 36e32ee4a6

View File

@ -86,6 +86,7 @@ type CallOnceOptions = {
## Parameters ## Parameters
- `key`: A unique key ensuring that the code is run once. If you do not provide a key, then a key that is unique to the file and line number of the instance of `callOnce` will be generated for you. - `key`: A unique key ensuring that the code is run once. If you do not provide a key, then a key that is unique to the file and line number of the instance of `callOnce` will be generated for you.
- `fn`: The function to run once. This function can also return a `Promise` and a value.
- `options`: Setup the mode, either to re-execute on navigation (`navigation`) or just once for the lifetime of the app (`render`). Defaults to `render`. - `options`: Setup the mode, either to re-execute on navigation (`navigation`) or just once for the lifetime of the app (`render`). Defaults to `render`.
- `render`: Executes once during initial render (either SSR or CSR) - Default mode - `render`: Executes once during initial render (either SSR or CSR) - Default mode
- `navigation`: Executes once during initial render and once per subsequent client-side navigation - `navigation`: Executes once during initial render and once per subsequent client-side navigation