NuxtN
Nuxt7mo ago
13 replies
zigglearner1235

Readonly reactive variables in pinia store

I am trying to mark a reactive variable in my pinia store as readonly() so it's only changed via setter but doing that yields a warning as [Vue warn] Set operation on key "value" failed: target is readonly. on initial page load.

How can I solve this?
Was this page helpful?