]> git.ipfire.org Git - thirdparty/vuejs/pinia.git/commitdiff
docs: update link (#1638)
authorgohomewho <51456572+ga676005@users.noreply.github.com>
Wed, 7 Sep 2022 21:28:33 +0000 (05:28 +0800)
committerGitHub <noreply@github.com>
Wed, 7 Sep 2022 21:28:33 +0000 (23:28 +0200)
one other thing is that `if (!Object.prototype.hasOwnProperty(store.$state, 'hello')) {` shown in the example below the link, I think the 'hello' should be 'secret'?

packages/docs/core-concepts/plugins.md

index 8594ad84a9896e93a7889aaf27e731660a7e0f90..bd63afd9f3b8d06d8709d9888aac7da5b51c71e1 100644 (file)
@@ -139,7 +139,7 @@ pinia.use(({ store }) => {
 Note that state changes or additions that occur within a plugin (that includes calling `store.$patch()`) happen before the store is active and therefore **do not trigger any subscriptions**.
 
 :::warning
-If you are using **Vue 2**, Pinia is subject to the [same reactivity caveats](https://vuejs.org/v2/guide/reactivity.html#Change-Detection-Caveats) as Vue. You will need to use `Vue.set()` (Vue 2.7) or `set()` (from `@vue/composition-api` for Vue <2.7) for when creating new state properties like `secret` and `hasError`:
+If you are using **Vue 2**, Pinia is subject to the [same reactivity caveats](https://v2.vuejs.org/v2/guide/reactivity.html#Change-Detection-Caveats) as Vue. You will need to use `Vue.set()` (Vue 2.7) or `set()` (from `@vue/composition-api` for Vue <2.7) for when creating new state properties like `secret` and `hasError`:
 
 ```js
 import { set, toRef } from '@vue/composition-api'