From 73c48be04d2899ad92d0a2d8a2df210025ebd14a Mon Sep 17 00:00:00 2001 From: Eduardo San Martin Morote Date: Wed, 3 Mar 2021 17:51:05 +0100 Subject: [PATCH] feat(nuxt): expose nuxt context as $nuxt --- nuxt/plugin.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nuxt/plugin.js b/nuxt/plugin.js index 12b9e116..42ea1aee 100644 --- a/nuxt/plugin.js +++ b/nuxt/plugin.js @@ -13,7 +13,7 @@ const myPlugin = (context, inject) => { context.app.pinia = pinia setActivePinia(pinia) - inject('pinia', pinia) + pinia.use(() => ({ $nuxt: context })) if (process.server) { context.beforeNuxtRender(({ nuxtState }) => { -- 2.47.3