You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
You may set an expiration time using the `until()` method. This method accepts a `DateTimeInterface`, `DateInterval`, or an integer (seconds). The prop will be refreshed on a subsequent visit after the expiration time has passed.
You may assign a custom key using the `as()` method. This is useful when you want to share data across multiple pages while using different prop names.
77
+
You may assign a custom key to the prop using the `as()` method. This is useful when you want to share data across multiple pages while using different prop names.
78
78
79
79
```php
80
80
// Team member list...
@@ -98,19 +98,19 @@ You may share once props globally using the `Inertia::share()` method.
You may also define a dedicated `shareOnce()` method in your middleware. The middleware will evaluate both `share()` and `shareOnce()`, merging the results.
113
+
Additionally, you may define a dedicated `shareOnce()` method in your middleware. The middleware will evaluate both `share()` and `shareOnce()`, merging the results.
114
114
115
115
```php
116
116
class HandleInertiaRequests extends Middleware
@@ -126,7 +126,7 @@ class HandleInertiaRequests extends Middleware
126
126
127
127
## Prefetching
128
128
129
-
Once props work with [prefetching](/v2/data-props/prefetching). The client automatically includes any remembered once props in prefetched responses, so navigating to a prefetched page will already have the once props available.
129
+
Once props are compatible with [prefetching](/v2/data-props/prefetching). The client automatically includes any remembered once props in prefetched responses, so navigating to a prefetched page will already have the once props available.
130
130
131
131
Prefetched pages containing an expired once prop will be invalidated from the cache.
0 commit comments