From: Eduardo San Martin Morote Date: Wed, 20 May 2020 12:56:16 +0000 (+0200) Subject: docs: disableVuex in nuxt.config.js X-Git-Tag: 0.0.6~12 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=f3e9a32d97ba5aa83329bc1e38cd7ed67119bc2e;p=thirdparty%2Fvuejs%2Fpinia.git docs: disableVuex in nuxt.config.js Close #160 --- diff --git a/README.md b/README.md index a7f0aa0c..babbd806 100644 --- a/README.md +++ b/README.md @@ -273,6 +273,14 @@ export default { } ``` +By default, it will also disable Vuex so you can directly use the `store` folder for pinia. If you want to keep using Vuex, you need to provide an option in `nuxt.config.js`: + +```js +export default { + disableVuex: false +} +``` + If you are dealing with SSR, in order to make sure the correct store is retrieved by `useStore` functions, pass the current `req` to `useStore`. **This is necessary anywhere not in the list above**: ```js