We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ea5b58e commit 264fb8bCopy full SHA for 264fb8b
1 file changed
src/runtime/composables/useLaravelIndex.ts
@@ -259,13 +259,18 @@ export function useLaravelIndex<T extends object>(
259
state.value.__hash = hash
260
}
261
262
+ let initialized = false
263
+
264
watch(
265
[
266
() => state.value.sort,
267
() => state.value.search,
268
() => state.value.filter,
269
],
270
() => {
271
+ if (!initialized) {
272
+ return
273
+ }
274
stateHash()
275
276
if (state.value.page) {
@@ -280,6 +285,9 @@ export function useLaravelIndex<T extends object>(
280
285
setConfig(options)
281
286
282
287
288
+ // Enable reactive loading after initial setup
289
+ initialized = true
290
283
291
return {
284
292
...toRefs(state.value),
293
state,
0 commit comments