Commit c9ab16a2 authored by Illya Klymov's avatar Illya Klymov

Merge branch...

Merge branch '338575-set-assumeimmutableresults-to-true-by-default-and-remove-it-from-createdefaultclient' into 'master'

Set `assumeImmutableResults` to `true` by default

See merge request gitlab-org/gitlab!73455
parents 69597558 c6f9101f
...@@ -49,7 +49,7 @@ export const initProjectsField = () => { ...@@ -49,7 +49,7 @@ export const initProjectsField = () => {
{ default: createDefaultClient }, { default: createDefaultClient },
]) => { ]) => {
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
Vue.use(VueApollo); Vue.use(VueApollo);
......
...@@ -15,7 +15,7 @@ import { ...@@ -15,7 +15,7 @@ import {
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
const initApp = (el, component, userPropKey, props = {}) => { const initApp = (el, component, userPropKey, props = {}) => {
......
...@@ -38,7 +38,6 @@ export default () => { ...@@ -38,7 +38,6 @@ export default () => {
return defaultDataIdFromObject(object); return defaultDataIdFromObject(object);
}, },
}, },
assumeImmutableResults: true,
}, },
), ),
}); });
......
...@@ -59,6 +59,5 @@ export default new VueApollo({ ...@@ -59,6 +59,5 @@ export default new VueApollo({
cacheConfig: { cacheConfig: {
fragmentMatcher, fragmentMatcher,
}, },
assumeImmutableResults: true,
}), }),
}); });
...@@ -6,7 +6,7 @@ import UsageTrendsApp from './components/app.vue'; ...@@ -6,7 +6,7 @@ import UsageTrendsApp from './components/app.vue';
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
export default () => { export default () => {
......
...@@ -6,7 +6,7 @@ import createDefaultClient from '~/lib/graphql'; ...@@ -6,7 +6,7 @@ import createDefaultClient from '~/lib/graphql';
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
export default (containerId = 'js-artifacts-settings-app') => { export default (containerId = 'js-artifacts-settings-app') => {
......
...@@ -17,6 +17,5 @@ export const gqlClient = createDefaultClient( ...@@ -17,6 +17,5 @@ export const gqlClient = createDefaultClient(
fragmentMatcher, fragmentMatcher,
}, },
assumeImmutableResults: true,
}, },
); );
...@@ -8,12 +8,7 @@ import { parseBoolean } from '~/lib/utils/common_utils'; ...@@ -8,12 +8,7 @@ import { parseBoolean } from '~/lib/utils/common_utils';
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(),
{},
{
assumeImmutableResults: true,
},
),
}); });
export default (params = {}) => { export default (params = {}) => {
......
...@@ -8,9 +8,7 @@ import CiLint from './components/ci_lint.vue'; ...@@ -8,9 +8,7 @@ import CiLint from './components/ci_lint.vue';
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient(resolvers, { defaultClient: createDefaultClient(resolvers),
assumeImmutableResults: true,
}),
}); });
export default (containerId = '#js-ci-lint') => { export default (containerId = '#js-ci-lint') => {
......
...@@ -12,12 +12,7 @@ export default () => { ...@@ -12,12 +12,7 @@ export default () => {
return null; return null;
} }
const defaultClient = createDefaultClient( const defaultClient = createDefaultClient();
{},
{
assumeImmutableResults: true,
},
);
const { agentName, projectPath } = el.dataset; const { agentName, projectPath } = el.dataset;
return new Vue({ return new Vue({
......
...@@ -8,7 +8,7 @@ export default (Vue, VueApollo) => { ...@@ -8,7 +8,7 @@ export default (Vue, VueApollo) => {
return null; return null;
} }
const defaultClient = createDefaultClient({}, { assumeImmutableResults: true }); const defaultClient = createDefaultClient();
const { const {
emptyStateImage, emptyStateImage,
......
...@@ -88,7 +88,6 @@ const defaultClient = createDefaultClient( ...@@ -88,7 +88,6 @@ const defaultClient = createDefaultClient(
fragmentMatcher, fragmentMatcher,
}, },
typeDefs, typeDefs,
assumeImmutableResults: true,
}, },
); );
......
...@@ -8,7 +8,7 @@ Vue.use(Translate); ...@@ -8,7 +8,7 @@ Vue.use(Translate);
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
export default () => { export default () => {
......
...@@ -2,16 +2,12 @@ import VueApollo from 'vue-apollo'; ...@@ -2,16 +2,12 @@ import VueApollo from 'vue-apollo';
import createDefaultClient from '~/lib/graphql'; import createDefaultClient from '~/lib/graphql';
import environmentApp from './queries/environmentApp.query.graphql'; import environmentApp from './queries/environmentApp.query.graphql';
import { resolvers } from './resolvers'; import { resolvers } from './resolvers';
import typedefs from './typedefs.graphql'; import typeDefs from './typedefs.graphql';
export const apolloProvider = (endpoint) => { export const apolloProvider = (endpoint) => {
const defaultClient = createDefaultClient( const defaultClient = createDefaultClient(resolvers(endpoint), {
resolvers(endpoint), typeDefs,
{ });
assumeImmutableResults: true,
},
typedefs,
);
const { cache } = defaultClient; const { cache } = defaultClient;
cache.writeQuery({ cache.writeQuery({
......
...@@ -9,7 +9,7 @@ Vue.use(Translate); ...@@ -9,7 +9,7 @@ Vue.use(Translate);
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
export default (el) => { export default (el) => {
......
...@@ -20,12 +20,7 @@ export default () => { ...@@ -20,12 +20,7 @@ export default () => {
} = domEl.dataset; } = domEl.dataset;
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(),
{},
{
assumeImmutableResults: true,
},
),
}); });
// eslint-disable-next-line no-new // eslint-disable-next-line no-new
......
...@@ -376,8 +376,4 @@ export function createResolvers({ endpoints, sourceUrl, GroupsManager = SourceGr ...@@ -376,8 +376,4 @@ export function createResolvers({ endpoints, sourceUrl, GroupsManager = SourceGr
} }
export const createApolloClient = ({ sourceUrl, endpoints }) => export const createApolloClient = ({ sourceUrl, endpoints }) =>
createDefaultClient( createDefaultClient(createResolvers({ sourceUrl, endpoints }), { typeDefs });
createResolvers({ sourceUrl, endpoints }),
{ assumeImmutableResults: true },
typeDefs,
);
...@@ -24,7 +24,7 @@ export default () => { ...@@ -24,7 +24,7 @@ export default () => {
} = domEl.dataset; } = domEl.dataset;
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
return new Vue({ return new Vue({
......
...@@ -10,12 +10,7 @@ export default function initIssuableSuggestions() { ...@@ -10,12 +10,7 @@ export default function initIssuableSuggestions() {
const issueTitle = document.getElementById('issue_title'); const issueTitle = document.getElementById('issue_title');
const { projectPath } = el.dataset; const { projectPath } = el.dataset;
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(),
{},
{
assumeImmutableResults: true,
},
),
}); });
return new Vue({ return new Vue({
......
...@@ -24,7 +24,7 @@ export function mountJiraIssuesListApp() { ...@@ -24,7 +24,7 @@ export function mountJiraIssuesListApp() {
} }
Vue.use(VueApollo); Vue.use(VueApollo);
const defaultClient = createDefaultClient({}, { assumeImmutableResults: true }); const defaultClient = createDefaultClient();
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient, defaultClient,
}); });
...@@ -103,7 +103,7 @@ export function mountIssuesListApp() { ...@@ -103,7 +103,7 @@ export function mountIssuesListApp() {
}, },
}; };
const defaultClient = createDefaultClient(resolvers, { assumeImmutableResults: true }); const defaultClient = createDefaultClient(resolvers);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient, defaultClient,
}); });
......
...@@ -14,12 +14,7 @@ export default async function initJiraConnectBranches() { ...@@ -14,12 +14,7 @@ export default async function initJiraConnectBranches() {
const { initialBranchName, successStateSvgPath } = el.dataset; const { initialBranchName, successStateSvgPath } = el.dataset;
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(),
{},
{
assumeImmutableResults: true,
},
),
}); });
return new Vue({ return new Vue({
......
...@@ -6,7 +6,7 @@ import App from './components/jira_import_app.vue'; ...@@ -6,7 +6,7 @@ import App from './components/jira_import_app.vue';
Vue.use(VueApollo); Vue.use(VueApollo);
const defaultClient = createDefaultClient({}, { assumeImmutableResults: true }); const defaultClient = createDefaultClient();
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient, defaultClient,
......
...@@ -9,12 +9,7 @@ Vue.use(VueApollo); ...@@ -9,12 +9,7 @@ Vue.use(VueApollo);
Vue.use(GlToast); Vue.use(GlToast);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(),
{},
{
assumeImmutableResults: true,
},
),
}); });
export default (containerId = 'js-jobs-table') => { export default (containerId = 'js-jobs-table') => {
......
...@@ -48,7 +48,6 @@ export const stripWhitespaceFromQuery = (url, path) => { ...@@ -48,7 +48,6 @@ export const stripWhitespaceFromQuery = (url, path) => {
export default (resolvers = {}, config = {}) => { export default (resolvers = {}, config = {}) => {
const { const {
assumeImmutableResults,
baseUrl, baseUrl,
batchMax = 10, batchMax = 10,
cacheConfig, cacheConfig,
...@@ -161,10 +160,10 @@ export default (resolvers = {}, config = {}) => { ...@@ -161,10 +160,10 @@ export default (resolvers = {}, config = {}) => {
link: appLink, link: appLink,
cache: new InMemoryCache({ cache: new InMemoryCache({
...cacheConfig, ...cacheConfig,
freezeResults: assumeImmutableResults, freezeResults: true,
}), }),
resolvers, resolvers,
assumeImmutableResults, assumeImmutableResults: true,
defaultOptions: { defaultOptions: {
query: { query: {
fetchPolicy, fetchPolicy,
......
...@@ -48,12 +48,7 @@ export default (elements) => { ...@@ -48,12 +48,7 @@ export default (elements) => {
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(),
{},
{
assumeImmutableResults: true,
},
),
}); });
const listenerAddedAttr = 'data-mr-listener-added'; const listenerAddedAttr = 'data-mr-listener-added';
......
...@@ -5,10 +5,5 @@ import createDefaultClient from '~/lib/graphql'; ...@@ -5,10 +5,5 @@ import createDefaultClient from '~/lib/graphql';
Vue.use(VueApollo); Vue.use(VueApollo);
export const apolloProvider = new VueApollo({ export const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(),
{},
{
assumeImmutableResults: true,
},
),
}); });
...@@ -17,7 +17,6 @@ export const apolloProvider = new VueApollo({ ...@@ -17,7 +17,6 @@ export const apolloProvider = new VueApollo({
cacheConfig: { cacheConfig: {
fragmentMatcher, fragmentMatcher,
}, },
assumeImmutableResults: true,
}, },
), ),
}); });
...@@ -5,10 +5,5 @@ import createDefaultClient from '~/lib/graphql'; ...@@ -5,10 +5,5 @@ import createDefaultClient from '~/lib/graphql';
Vue.use(VueApollo); Vue.use(VueApollo);
export const apolloProvider = new VueApollo({ export const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(),
{},
{
assumeImmutableResults: true,
},
),
}); });
...@@ -5,10 +5,5 @@ import createDefaultClient from '~/lib/graphql'; ...@@ -5,10 +5,5 @@ import createDefaultClient from '~/lib/graphql';
Vue.use(VueApollo); Vue.use(VueApollo);
export const apolloProvider = new VueApollo({ export const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(),
{},
{
assumeImmutableResults: true,
},
),
}); });
...@@ -14,7 +14,7 @@ import '~/sourcegraph/load'; ...@@ -14,7 +14,7 @@ import '~/sourcegraph/load';
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
const viewBlobEl = document.querySelector('#js-view-blob-app'); const viewBlobEl = document.querySelector('#js-view-blob-app');
......
...@@ -28,7 +28,7 @@ export default function initMergeRequestShow() { ...@@ -28,7 +28,7 @@ export default function initMergeRequestShow() {
const el = document.querySelector('.js-mr-status-box'); const el = document.querySelector('.js-mr-status-box');
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
// eslint-disable-next-line no-new // eslint-disable-next-line no-new
new Vue({ new Vue({
......
...@@ -9,12 +9,7 @@ export function initInstallRunner(componentId = 'js-install-runner') { ...@@ -9,12 +9,7 @@ export function initInstallRunner(componentId = 'js-install-runner') {
const installRunnerEl = document.getElementById(componentId); const installRunnerEl = document.getElementById(componentId);
if (installRunnerEl) { if (installRunnerEl) {
const defaultClient = createDefaultClient( const defaultClient = createDefaultClient();
{},
{
assumeImmutableResults: true,
},
);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient, defaultClient,
......
...@@ -61,7 +61,6 @@ export const initPipelineEditor = (selector = '#js-pipeline-editor') => { ...@@ -61,7 +61,6 @@ export const initPipelineEditor = (selector = '#js-pipeline-editor') => {
defaultClient: createDefaultClient(resolvers, { defaultClient: createDefaultClient(resolvers, {
typeDefs, typeDefs,
useGet: true, useGet: true,
assumeImmutableResults: true,
}), }),
}); });
const { cache } = apolloProvider.clients.defaultClient; const { cache } = apolloProvider.clients.defaultClient;
......
...@@ -5,7 +5,6 @@ export const apolloProvider = new VueApollo({ ...@@ -5,7 +5,6 @@ export const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(
{}, {},
{ {
assumeImmutableResults: true,
useGet: true, useGet: true,
}, },
), ),
......
...@@ -5,12 +5,7 @@ import createDefaultClient from '~/lib/graphql'; ...@@ -5,12 +5,7 @@ import createDefaultClient from '~/lib/graphql';
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(),
{},
{
assumeImmutableResults: true,
},
),
}); });
export const initCommitPipelineMiniGraph = async (selector = '.js-commit-pipeline-mini-graph') => { export const initCommitPipelineMiniGraph = async (selector = '.js-commit-pipeline-mini-graph') => {
......
...@@ -50,7 +50,7 @@ export function initNewProjectUrlSelect() { ...@@ -50,7 +50,7 @@ export function initNewProjectUrlSelect() {
new Vue({ new Vue({
el, el,
apolloProvider: new VueApollo({ apolloProvider: new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}), }),
provide: { provide: {
namespaceFullPath: el.dataset.namespaceFullPath, namespaceFullPath: el.dataset.namespaceFullPath,
......
...@@ -7,7 +7,7 @@ import ProjectPipelinesCharts from './components/app.vue'; ...@@ -7,7 +7,7 @@ import ProjectPipelinesCharts from './components/app.vue';
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
const mountPipelineChartsApp = (el) => { const mountPipelineChartsApp = (el) => {
......
...@@ -25,7 +25,7 @@ export default (containerId = 'js-project-storage-count-app') => { ...@@ -25,7 +25,7 @@ export default (containerId = 'js-project-storage-count-app') => {
} = el.dataset; } = el.dataset;
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
return new Vue({ return new Vue({
......
...@@ -6,7 +6,7 @@ import TerraformNotification from './components/terraform_notification.vue'; ...@@ -6,7 +6,7 @@ import TerraformNotification from './components/terraform_notification.vue';
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmtableResults: true }), defaultClient: createDefaultClient(),
}); });
export default () => { export default () => {
......
...@@ -9,7 +9,6 @@ export const apolloProvider = new VueApollo({ ...@@ -9,7 +9,6 @@ export const apolloProvider = new VueApollo({
{}, {},
{ {
batchMax: 1, batchMax: 1,
assumeImmutableResults: true,
}, },
), ),
}); });
...@@ -24,7 +24,6 @@ export default () => { ...@@ -24,7 +24,6 @@ export default () => {
// the purpose of making separate requests. So we explicitly // the purpose of making separate requests. So we explicitly
// disable batching on this page. // disable batching on this page.
batchMax: 1, batchMax: 1,
assumeImmutableResults: true,
}, },
), ),
}); });
......
...@@ -6,12 +6,7 @@ import ReleaseShowApp from './components/app_show.vue'; ...@@ -6,12 +6,7 @@ import ReleaseShowApp from './components/app_show.vue';
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(),
{},
{
assumeImmutableResults: true,
},
),
}); });
export default () => { export default () => {
......
...@@ -64,7 +64,6 @@ const defaultClient = createDefaultClient( ...@@ -64,7 +64,6 @@ const defaultClient = createDefaultClient(
/* eslint-enable @gitlab/require-i18n-strings */ /* eslint-enable @gitlab/require-i18n-strings */
}, },
}, },
assumeImmutableResults: true,
}, },
); );
......
...@@ -19,12 +19,7 @@ export const initAdminRunners = (selector = '#js-admin-runners') => { ...@@ -19,12 +19,7 @@ export const initAdminRunners = (selector = '#js-admin-runners') => {
const { activeRunnersCount, registrationToken, runnerInstallHelpPage } = el.dataset; const { activeRunnersCount, registrationToken, runnerInstallHelpPage } = el.dataset;
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(),
{},
{
assumeImmutableResults: true,
},
),
}); });
return new Vue({ return new Vue({
......
...@@ -23,12 +23,7 @@ export const initGroupRunners = (selector = '#js-group-runners') => { ...@@ -23,12 +23,7 @@ export const initGroupRunners = (selector = '#js-group-runners') => {
} = el.dataset; } = el.dataset;
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(),
{},
{
assumeImmutableResults: true,
},
),
}); });
return new Vue({ return new Vue({
......
...@@ -15,12 +15,7 @@ export const initRunnerDetail = (selector = '#js-runner-details') => { ...@@ -15,12 +15,7 @@ export const initRunnerDetail = (selector = '#js-runner-details') => {
const { runnerId } = el.dataset; const { runnerId } = el.dataset;
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(),
{},
{
assumeImmutableResults: true,
},
),
}); });
return new Vue({ return new Vue({
......
...@@ -14,7 +14,7 @@ export const initSecurityConfiguration = (el) => { ...@@ -14,7 +14,7 @@ export const initSecurityConfiguration = (el) => {
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
const { const {
......
...@@ -25,7 +25,6 @@ export const defaultClient = createDefaultClient(resolvers, { ...@@ -25,7 +25,6 @@ export const defaultClient = createDefaultClient(resolvers, {
cacheConfig: { cacheConfig: {
fragmentMatcher, fragmentMatcher,
}, },
assumeImmutableResults: true,
}); });
export const apolloProvider = new VueApollo({ export const apolloProvider = new VueApollo({
......
...@@ -18,7 +18,6 @@ export default function appFactory(el, Component) { ...@@ -18,7 +18,6 @@ export default function appFactory(el, Component) {
{}, {},
{ {
batchMax: 1, batchMax: 1,
assumeImmutableResults: true,
}, },
), ),
}); });
......
...@@ -22,7 +22,6 @@ const createApolloProvider = (appData) => { ...@@ -22,7 +22,6 @@ const createApolloProvider = (appData) => {
}, },
{ {
typeDefs, typeDefs,
assumeImmutableResults: true,
}, },
); );
......
...@@ -22,7 +22,6 @@ export default () => { ...@@ -22,7 +22,6 @@ export default () => {
return object.id || defaultDataIdFromObject(object); return object.id || defaultDataIdFromObject(object);
}, },
}, },
assumeImmutableResults: true,
}); });
const { emptyStateImage, projectPath, accessTokensPath, terraformApiUrl, username } = el.dataset; const { emptyStateImage, projectPath, accessTokensPath, terraformApiUrl, username } = el.dataset;
......
...@@ -6,7 +6,7 @@ import TokenAccess from './components/token_access.vue'; ...@@ -6,7 +6,7 @@ import TokenAccess from './components/token_access.vue';
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
export const initTokenAccess = (containerId = 'js-ci-token-access-app') => { export const initTokenAccess = (containerId = 'js-ci-token-access-app') => {
......
...@@ -13,12 +13,7 @@ Vue.use(Translate); ...@@ -13,12 +13,7 @@ Vue.use(Translate);
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(),
{},
{
assumeImmutableResults: true,
},
),
}); });
export default () => { export default () => {
......
...@@ -38,7 +38,6 @@ export default (selector) => { ...@@ -38,7 +38,6 @@ export default (selector) => {
return defaultDataIdFromObject(object); return defaultDataIdFromObject(object);
}, },
}, },
assumeImmutableResults: true,
}), }),
}); });
......
...@@ -5,5 +5,5 @@ import createDefaultClient from '~/lib/graphql'; ...@@ -5,5 +5,5 @@ import createDefaultClient from '~/lib/graphql';
Vue.use(VueApollo); Vue.use(VueApollo);
export default new VueApollo({ export default new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
...@@ -4,6 +4,7 @@ import { IntrospectionFragmentMatcher } from 'apollo-cache-inmemory'; ...@@ -4,6 +4,7 @@ import { IntrospectionFragmentMatcher } from 'apollo-cache-inmemory';
import createDefaultClient from '~/lib/graphql'; import createDefaultClient from '~/lib/graphql';
import workItemQuery from './work_item.query.graphql'; import workItemQuery from './work_item.query.graphql';
import introspectionQueryResultData from './fragmentTypes.json'; import introspectionQueryResultData from './fragmentTypes.json';
import typeDefs from './typedefs.graphql';
const fragmentMatcher = new IntrospectionFragmentMatcher({ const fragmentMatcher = new IntrospectionFragmentMatcher({
introspectionQueryResultData, introspectionQueryResultData,
...@@ -18,7 +19,7 @@ export function createApolloProvider() { ...@@ -18,7 +19,7 @@ export function createApolloProvider() {
cacheConfig: { cacheConfig: {
fragmentMatcher, fragmentMatcher,
}, },
assumeImmutableResults: true, typeDefs,
}, },
); );
......
...@@ -103,7 +103,6 @@ Default client accepts two parameters: `resolvers` and `config`. ...@@ -103,7 +103,6 @@ Default client accepts two parameters: `resolvers` and `config`.
- `config` parameter takes an object of configuration settings: - `config` parameter takes an object of configuration settings:
- `cacheConfig` field accepts an optional object of settings to [customize Apollo cache](https://www.apollographql.com/docs/react/caching/cache-configuration/#configuring-the-cache) - `cacheConfig` field accepts an optional object of settings to [customize Apollo cache](https://www.apollographql.com/docs/react/caching/cache-configuration/#configuring-the-cache)
- `baseUrl` allows us to pass a URL for GraphQL endpoint different from our main endpoint (for example, `${gon.relative_url_root}/api/graphql`) - `baseUrl` allows us to pass a URL for GraphQL endpoint different from our main endpoint (for example, `${gon.relative_url_root}/api/graphql`)
- `assumeImmutableResults` (set to `false` by default) - this setting, when set to `true`, assumes that every single operation on updating Apollo Cache is immutable. It also sets `freezeResults` to `true`, so any attempt on mutating Apollo Cache throws a console warning in development environment. Please ensure you're following the immutability pattern on cache update operations before setting this option to `true`.
- `fetchPolicy` determines how you want your component to interact with the Apollo cache. Defaults to "cache-first". - `fetchPolicy` determines how you want your component to interact with the Apollo cache. Defaults to "cache-first".
### Multiple client queries for the same object ### Multiple client queries for the same object
...@@ -179,7 +178,7 @@ with a **new and updated** object. ...@@ -179,7 +178,7 @@ with a **new and updated** object.
To facilitate the process of updating the cache and returning the new object we To facilitate the process of updating the cache and returning the new object we
use the library [Immer](https://immerjs.github.io/immer/). use the library [Immer](https://immerjs.github.io/immer/).
When possible, follow these conventions: Please, follow these conventions:
- The updated cache is named `data`. - The updated cache is named `data`.
- The original cache data is named `sourceData`. - The original cache data is named `sourceData`.
...@@ -204,11 +203,6 @@ client.writeQuery({ ...@@ -204,11 +203,6 @@ client.writeQuery({
As shown in the code example by using `produce`, we can perform any kind of direct manipulation of the As shown in the code example by using `produce`, we can perform any kind of direct manipulation of the
`draftState`. Besides, `immer` guarantees that a new state which includes the changes to `draftState` is generated. `draftState`. Besides, `immer` guarantees that a new state which includes the changes to `draftState` is generated.
Finally, to verify whether the immutable cache update is working properly, we need to change
`assumeImmutableResults` to `true` in the default client configuration. See [Apollo Client](#apollo-client) for more information.
If everything is working properly `assumeImmutableResults` should remain set to `true`.
## Usage in Vue ## Usage in Vue
To use Vue Apollo, import the [Vue Apollo](https://github.com/vuejs/vue-apollo) plugin as well To use Vue Apollo, import the [Vue Apollo](https://github.com/vuejs/vue-apollo) plugin as well
......
...@@ -8,12 +8,7 @@ import CloudLicenseShowApp from './components/app.vue'; ...@@ -8,12 +8,7 @@ import CloudLicenseShowApp from './components/app.vue';
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(),
{},
{
assumeImmutableResults: true,
},
),
}); });
export default () => { export default () => {
......
...@@ -14,12 +14,7 @@ Vue.use(GlToast); ...@@ -14,12 +14,7 @@ Vue.use(GlToast);
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(),
{},
{
assumeImmutableResults: true,
},
),
}); });
export default () => { export default () => {
......
...@@ -34,5 +34,5 @@ export const createResolvers = (groupId) => ({ ...@@ -34,5 +34,5 @@ export const createResolvers = (groupId) => ({
export const createApolloProvider = (groupId) => export const createApolloProvider = (groupId) =>
new VueApollo({ new VueApollo({
defaultClient: createDefaultClient(createResolvers(groupId), { assumeImmutableResults: true }), defaultClient: createDefaultClient(createResolvers(groupId)),
}); });
...@@ -7,7 +7,7 @@ import CiCdAnalyticsApp from './components/app.vue'; ...@@ -7,7 +7,7 @@ import CiCdAnalyticsApp from './components/app.vue';
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
export default () => { export default () => {
......
...@@ -11,7 +11,7 @@ import { parseAndValidateDates } from './utils'; ...@@ -11,7 +11,7 @@ import { parseAndValidateDates } from './utils';
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
export default () => { export default () => {
......
...@@ -15,7 +15,7 @@ import { getLabelsEndpoint, getMilestonesEndpoint } from './utils'; ...@@ -15,7 +15,7 @@ import { getLabelsEndpoint, getMilestonesEndpoint } from './utils';
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
export default () => { export default () => {
......
...@@ -6,7 +6,7 @@ import GroupRepositoryAnalytics from './components/group_repository_analytics.vu ...@@ -6,7 +6,7 @@ import GroupRepositoryAnalytics from './components/group_repository_analytics.vu
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
export default () => { export default () => {
......
...@@ -9,7 +9,7 @@ import BurnCharts from './components/burn_charts.vue'; ...@@ -9,7 +9,7 @@ import BurnCharts from './components/burn_charts.vue';
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
export default () => { export default () => {
......
...@@ -7,7 +7,7 @@ import CiMinutesUsageApp from './components/app.vue'; ...@@ -7,7 +7,7 @@ import CiMinutesUsageApp from './components/app.vue';
const mountCiMinutesUsageApp = (el) => { const mountCiMinutesUsageApp = (el) => {
Vue.use(VueApollo); Vue.use(VueApollo);
const defaultClient = createDefaultClient({}, { assumeImmutableResults: true }); const defaultClient = createDefaultClient();
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient, defaultClient,
}); });
......
...@@ -6,12 +6,7 @@ import EpicForm from './components/epic_form.vue'; ...@@ -6,12 +6,7 @@ import EpicForm from './components/epic_form.vue';
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(),
{},
{
assumeImmutableResults: true,
},
),
}); });
export function initEpicForm() { export function initEpicForm() {
......
...@@ -32,7 +32,6 @@ const apolloProvider = new VueApollo({ ...@@ -32,7 +32,6 @@ const apolloProvider = new VueApollo({
cacheConfig: { cacheConfig: {
fragmentMatcher, fragmentMatcher,
}, },
assumeImmutableResults: true,
}, },
), ),
}); });
......
...@@ -18,12 +18,7 @@ export default function initEpicsList({ mountPointSelector }) { ...@@ -18,12 +18,7 @@ export default function initEpicsList({ mountPointSelector }) {
} }
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(),
{},
{
assumeImmutableResults: true,
},
),
}); });
const { const {
......
...@@ -19,7 +19,6 @@ const apolloProvider = new VueApollo({ ...@@ -19,7 +19,6 @@ const apolloProvider = new VueApollo({
return defaultDataIdFromObject(object); return defaultDataIdFromObject(object);
}, },
}, },
assumeImmutableResults: true,
}, },
), ),
}); });
......
...@@ -11,7 +11,7 @@ export default (externalIssuesQueryResolver) => { ...@@ -11,7 +11,7 @@ export default (externalIssuesQueryResolver) => {
}, },
}; };
const defaultClient = createDefaultClient(resolvers, { assumeImmutableResults: true }); const defaultClient = createDefaultClient(resolvers);
return new VueApollo({ return new VueApollo({
defaultClient, defaultClient,
......
...@@ -9,7 +9,7 @@ import EditForm from './components/edit_form.vue'; ...@@ -9,7 +9,7 @@ import EditForm from './components/edit_form.vue';
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
const createComplianceFrameworksFormApp = (el) => { const createComplianceFrameworksFormApp = (el) => {
......
...@@ -7,7 +7,7 @@ import Form from './components/list.vue'; ...@@ -7,7 +7,7 @@ import Form from './components/list.vue';
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
const createComplianceFrameworksListApp = (el) => { const createComplianceFrameworksListApp = (el) => {
......
...@@ -19,7 +19,6 @@ const apolloProvider = new VueApollo({ ...@@ -19,7 +19,6 @@ const apolloProvider = new VueApollo({
{}, {},
{ {
batchMax: 1, batchMax: 1,
assumeImmutableResults: true,
}, },
), ),
}); });
......
...@@ -4,12 +4,7 @@ import createDefaultClient from '~/lib/graphql'; ...@@ -4,12 +4,7 @@ import createDefaultClient from '~/lib/graphql';
Vue.use(VueApollo); Vue.use(VueApollo);
const defaultClient = createDefaultClient( const defaultClient = createDefaultClient();
{},
{
assumeImmutableResults: true,
},
);
export default new VueApollo({ export default new VueApollo({
defaultClient, defaultClient,
......
...@@ -5,5 +5,5 @@ import createDefaultClient from '~/lib/graphql'; ...@@ -5,5 +5,5 @@ import createDefaultClient from '~/lib/graphql';
Vue.use(VueApollo); Vue.use(VueApollo);
export default new VueApollo({ export default new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
...@@ -19,8 +19,5 @@ const resolvers = { ...@@ -19,8 +19,5 @@ const resolvers = {
}; };
export default new VueApollo({ export default new VueApollo({
defaultClient: createDefaultClient(resolvers, { defaultClient: createDefaultClient(resolvers),
cacheConfig: {},
assumeImmutableResults: true,
}),
}); });
...@@ -47,7 +47,7 @@ const fetchMergeOptions = () => { ...@@ -47,7 +47,7 @@ const fetchMergeOptions = () => {
const containerEl = document.querySelector('#project-merge-options'); const containerEl = document.querySelector('#project-merge-options');
const { projectFullPath } = containerEl.dataset; const { projectFullPath } = containerEl.dataset;
const defaultClient = createDefaultClient({}, { assumeImmutableResults: true }); const defaultClient = createDefaultClient();
return defaultClient return defaultClient
.query({ .query({
......
...@@ -34,7 +34,6 @@ export default () => { ...@@ -34,7 +34,6 @@ export default () => {
object.__typename === 'Requirement' ? object.iid : defaultDataIdFromObject(object), object.__typename === 'Requirement' ? object.iid : defaultDataIdFromObject(object),
fragmentMatcher, fragmentMatcher,
}, },
assumeImmutableResults: true,
}, },
), ),
}); });
......
...@@ -30,7 +30,7 @@ export default () => { ...@@ -30,7 +30,7 @@ export default () => {
} }
Vue.use(VueApollo); Vue.use(VueApollo);
const defaultClient = createDefaultClient({}, { assumeImmutableResults: true }); const defaultClient = createDefaultClient();
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient, defaultClient,
}); });
......
...@@ -5,10 +5,5 @@ import createDefaultClient from '~/lib/graphql'; ...@@ -5,10 +5,5 @@ import createDefaultClient from '~/lib/graphql';
Vue.use(VueApollo); Vue.use(VueApollo);
export const apolloProvider = new VueApollo({ export const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(),
{},
{
assumeImmutableResults: true,
},
),
}); });
...@@ -15,7 +15,6 @@ export default () => { ...@@ -15,7 +15,6 @@ export default () => {
} }
const defaultClient = createDefaultClient(resolvers, { const defaultClient = createDefaultClient(resolvers, {
assumeImmutableResults: true,
cacheConfig: { cacheConfig: {
dataIdFromObject: (object) => { dataIdFromObject: (object) => {
return object.id || defaultDataIdFromObject(object); return object.id || defaultDataIdFromObject(object);
......
...@@ -13,7 +13,7 @@ export default function init() { ...@@ -13,7 +13,7 @@ export default function init() {
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
const { const {
......
...@@ -5,5 +5,5 @@ import createDefaultClient from '~/lib/graphql'; ...@@ -5,5 +5,5 @@ import createDefaultClient from '~/lib/graphql';
Vue.use(VueApollo); Vue.use(VueApollo);
export default new VueApollo({ export default new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
...@@ -5,5 +5,5 @@ import createDefaultClient from '~/lib/graphql'; ...@@ -5,5 +5,5 @@ import createDefaultClient from '~/lib/graphql';
Vue.use(VueApollo); Vue.use(VueApollo);
export default new VueApollo({ export default new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
...@@ -5,5 +5,5 @@ import createDefaultClient from '~/lib/graphql'; ...@@ -5,5 +5,5 @@ import createDefaultClient from '~/lib/graphql';
Vue.use(VueApollo); Vue.use(VueApollo);
export default new VueApollo({ export default new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
...@@ -5,5 +5,5 @@ import createDefaultClient from '~/lib/graphql'; ...@@ -5,5 +5,5 @@ import createDefaultClient from '~/lib/graphql';
Vue.use(VueApollo); Vue.use(VueApollo);
export default new VueApollo({ export default new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
...@@ -13,7 +13,7 @@ export default function init() { ...@@ -13,7 +13,7 @@ export default function init() {
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
const { const {
......
...@@ -18,7 +18,6 @@ const defaultClient = createDefaultClient( ...@@ -18,7 +18,6 @@ const defaultClient = createDefaultClient(
cacheConfig: { cacheConfig: {
fragmentMatcher, fragmentMatcher,
}, },
assumeImmutableResults: true,
}, },
); );
......
...@@ -15,7 +15,7 @@ export default () => { ...@@ -15,7 +15,7 @@ export default () => {
} = el.dataset; } = el.dataset;
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
return new Vue({ return new Vue({
......
...@@ -11,14 +11,13 @@ Vue.use(VueApollo); ...@@ -11,14 +11,13 @@ Vue.use(VueApollo);
const gitlabClient = createClient(merge({}, resolvers, purchaseFlowResolvers), { const gitlabClient = createClient(merge({}, resolvers, purchaseFlowResolvers), {
typeDefs, typeDefs,
assumeImmutableResults: true,
}); });
const customersDotClient = createClient( const customersDotClient = createClient(
{}, {},
{ {
path: '/-/customers_dot/proxy/graphql', path: '/-/customers_dot/proxy/graphql',
useGet: true, useGet: true,
assumeImmutableResults: true,
}, },
); );
......
...@@ -8,7 +8,6 @@ import { STEPS } from '../constants'; ...@@ -8,7 +8,6 @@ import { STEPS } from '../constants';
function createClient(stepList) { function createClient(stepList) {
const client = createDefaultClient(resolvers, { const client = createDefaultClient(resolvers, {
typeDefs, typeDefs,
assumeImmutableResults: true,
}); });
client.cache.writeQuery({ client.cache.writeQuery({
......
...@@ -15,7 +15,7 @@ export function initTestCaseCreate({ mountPointSelector }) { ...@@ -15,7 +15,7 @@ export function initTestCaseCreate({ mountPointSelector }) {
} }
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
return new Vue({ return new Vue({
......
...@@ -19,7 +19,7 @@ const initTestCaseList = ({ mountPointSelector }) => { ...@@ -19,7 +19,7 @@ const initTestCaseList = ({ mountPointSelector }) => {
} }
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
const { const {
......
...@@ -16,7 +16,7 @@ export default function initTestCaseShow({ mountPointSelector }) { ...@@ -16,7 +16,7 @@ export default function initTestCaseShow({ mountPointSelector }) {
} }
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
const sidebarOptions = JSON.parse(el.dataset.sidebarOptions); const sidebarOptions = JSON.parse(el.dataset.sidebarOptions);
......
...@@ -12,7 +12,6 @@ const apolloProvider = new VueApollo({ ...@@ -12,7 +12,6 @@ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient( defaultClient: createDefaultClient(
{}, {},
{ {
assumeImmutableResults: true,
cacheConfig: { cacheConfig: {
dataIdFromObject: (object) => { dataIdFromObject: (object) => {
// eslint-disable-next-line no-underscore-dangle // eslint-disable-next-line no-underscore-dangle
......
...@@ -9,7 +9,7 @@ import createStore from './store'; ...@@ -9,7 +9,7 @@ import createStore from './store';
Vue.use(VueApollo); Vue.use(VueApollo);
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
export default () => { export default () => {
......
...@@ -50,9 +50,4 @@ export const removeUnnecessaryDashes = (manifest) => { ...@@ -50,9 +50,4 @@ export const removeUnnecessaryDashes = (manifest) => {
/** /**
* Create GraphQL Client for threat monitoring * Create GraphQL Client for threat monitoring
*/ */
export const gqClient = createGqClient( export const gqClient = createGqClient();
{},
{
assumeImmutableResults: true,
},
);
...@@ -15,7 +15,7 @@ export default function initIterationsDropdownBundle() { ...@@ -15,7 +15,7 @@ export default function initIterationsDropdownBundle() {
} }
const apolloProvider = new VueApollo({ const apolloProvider = new VueApollo({
defaultClient: createDefaultClient({}, { assumeImmutableResults: true }), defaultClient: createDefaultClient(),
}); });
const { fullPath } = el.dataset; const { fullPath } = el.dataset;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment