From c2f831acf70d3ed3bf1a0f3e487d468ea8573316 Mon Sep 17 00:00:00 2001 From: Fabians Geikins Date: Thu, 26 Feb 2026 18:37:28 +0200 Subject: [PATCH] fix: remove forced SSR fetch policy --- packages/vue-apollo-composable/src/useQuery.ts | 5 ----- packages/vue-apollo-option/src/smart-query.js | 4 ---- 2 files changed, 9 deletions(-) diff --git a/packages/vue-apollo-composable/src/useQuery.ts b/packages/vue-apollo-composable/src/useQuery.ts index c50ed24..aa44a65 100644 --- a/packages/vue-apollo-composable/src/useQuery.ts +++ b/packages/vue-apollo-composable/src/useQuery.ts @@ -280,11 +280,6 @@ export function useQueryImpl< query: currentDocument, variables: currentVariables ?? {} as TVariables, ...currentOptions.value, - ...(isServer && currentOptions.value?.fetchPolicy !== 'no-cache') - ? { - fetchPolicy: 'network-only', - } - : {}, }) startQuerySubscription() diff --git a/packages/vue-apollo-option/src/smart-query.js b/packages/vue-apollo-option/src/smart-query.js index d415295..4ec80e9 100644 --- a/packages/vue-apollo-option/src/smart-query.js +++ b/packages/vue-apollo-option/src/smart-query.js @@ -30,10 +30,6 @@ export default class SmartQuery extends SmartApollo { }) } - if (isServer) { - this.options.fetchPolicy = 'network-only' - } - if (!options.manual) { this.hasDataField = Object.prototype.hasOwnProperty.call(this.vm.$data, key) if (this.hasDataField) {