From 80abf5ee9296d1e5d6b97a6b599d388565469d8c Mon Sep 17 00:00:00 2001 From: Eduardo San Martin Morote Date: Wed, 3 Mar 2021 16:14:43 +0100 Subject: [PATCH] refactor: remove unused code --- nuxt/plugin.js | 7 ++----- src/rootStore.ts | 1 - 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/nuxt/plugin.js b/nuxt/plugin.js index c00ea7a9..abbe3581 100644 --- a/nuxt/plugin.js +++ b/nuxt/plugin.js @@ -1,16 +1,13 @@ // @ts-check import Vue from 'vue' // @ts-ignore: this must be pinia to load the local module -import { setActiveReq, PiniaSsr, setStateProvider, getRootState } from 'pinia' - -if (process.server) { - Vue.use(PiniaSsr) -} +import { setActiveReq, setStateProvider, getRootState } from 'pinia' /** @type {import('@nuxt/types').Plugin} */ const myPlugin = (context) => { // console.log('🍍 Pinia Nuxt plugin installed') + // TODO: figure this out if (process.server) { setActiveReq(context.req) context.beforeNuxtRender(({ nuxtState }) => { diff --git a/src/rootStore.ts b/src/rootStore.ts index 2cc4a6c7..4326ce3e 100644 --- a/src/rootStore.ts +++ b/src/rootStore.ts @@ -117,7 +117,6 @@ export interface Pinia { Vue: VueConstructor } -export const IS_CLIENT = typeof window !== 'undefined' /** * Creates a Pinia instance to be used by the application -- 2.47.3