Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

186
Visualizações
How can I use vuex-persistedstate on Nuxt for only specific stores?

This is the library: https://github.com/robinvdvleuten/vuex-persistedstate. I created the following plugin file for Nuxt.

import createPersistedState from 'vuex-persistedstate'

export default ({ store }) => {
  createPersistedState()(store)
}

The problem is I am not sure how I can exlude certain stores since this persists all the stores.

almost 4 years ago · Santiago Trujillo
1 Respostas
Responde à pergunta

0

The repo you're sharing is archived as of today so you should probably pass on it and switch to Pinia.

There are 2 packages doing that with Pinia:

  • https://prazdevs.github.io/pinia-plugin-persistedstate/guide/advanced.html#multiple-persistences-per-store
  • https://seb-l.github.io/pinia-plugin-persist/advanced/custom-key.html

Otherwise, a homemade solution may be needed but vuex-persistedstate will not allow you to select a store as you initially wanted.

almost 4 years ago · Santiago Trujillo Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda