Replies: 1 comment 2 replies
-
@posva do you know if this is a bug, or intended behavior? |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I've got the following pages / routes in my Vue app:
/clients/[clientId]
/clients/[clientId]/orders/[orderId]
Page 1 consists of 2 columns: on the left, the general information of the client is shown, which is loaded through the
useClient()
loader. The right column is a child<RouterView>
, which shows an overview of the client's orders on page 1 (useOrders()
), and a specific order on page 2 (useCurrentOrder()
).The general client information only has to be loaded once, as soon as the user navigates to page 1. However, as soon as the user navigates from page 1 to page 2, I noticed that the
useClient()
data loader is being reloaded, as it fetches all client data again. As the client's data does not change in this case, I actually do not want theuseClient()
loader to reload. How can I solve this?My route structure looks like this:
useClient()
is exported in[clientId].vue
, whereasuseOrders()
is exported in[clientId]/index.vue
.Beta Was this translation helpful? Give feedback.
All reactions