diff --git a/packages/docs/cookbook/testing.md b/packages/docs/cookbook/testing.md index 657ae7b402..bc7300b6de 100644 --- a/packages/docs/cookbook/testing.md +++ b/packages/docs/cookbook/testing.md @@ -168,7 +168,7 @@ expect(store.someAction).toHaveBeenCalledTimes(1) ### Mocking the returned value of an action -Actions are automatically spied but type-wise, they are still the regular actions. In order to get the correct type, we must implement a custom type-wrapper that is applies the `Mock` type to each action. **This type depends on the testing framework you are using**. Here is an example with Vitest: +Actions are automatically spied but type-wise, they are still the regular actions. In order to get the correct type, we must implement a custom type-wrapper that applies the `Mock` type to each action. **This type depends on the testing framework you are using**. Here is an example with Vitest: ```ts import type { Mock } from 'vitest' diff --git a/packages/docs/core-concepts/plugins.md b/packages/docs/core-concepts/plugins.md index f784ec0dcf..b7dc4697f0 100644 --- a/packages/docs/core-concepts/plugins.md +++ b/packages/docs/core-concepts/plugins.md @@ -112,7 +112,7 @@ This is why you can access all computed properties without `.value` and why they If you want to add new state properties to a store or properties that are meant to be used during hydration, **you will have to add it in two places**: - On the `store` so you can access it with `store.myState` -- On `store.$state` so it can be used in devtools and, **be serialized during SSR**. +- On `store.$state` so it can be used in devtools and **be serialized during SSR**. On top of that, you will certainly have to use a `ref()` (or other reactive API) in order to share the value across different accesses: diff --git a/packages/docs/introduction.md b/packages/docs/introduction.md index 62eb986b7e..27c69652e0 100644 --- a/packages/docs/introduction.md +++ b/packages/docs/introduction.md @@ -24,9 +24,9 @@ Pinia is a store library for Vue, it allows you to share a state across componen - Testing utilities - Plugins: extend Pinia features with plugins - Proper TypeScript support or **autocompletion** for JS users -- Server Side Rendering Support +- Server Side Rendering support - Devtools support - - A timeline to track actions, mutations + - A timeline to track actions and mutations - Stores appear in components where they are used - Time travel and easier debugging - Hot module replacement diff --git a/packages/docs/zh/cookbook/testing.md b/packages/docs/zh/cookbook/testing.md index 66dfe21861..745f9296b9 100644 --- a/packages/docs/zh/cookbook/testing.md +++ b/packages/docs/zh/cookbook/testing.md @@ -175,7 +175,7 @@ expect(store.someAction).toHaveBeenCalledTimes(1) ### Mocking the returned value of an action -Actions are automatically spied but type-wise, they are still the regular actions. In order to get the correct type, we must implement a custom type-wrapper that is applies the `Mock` type to each action. **This type depends on the testing framework you are using**. Here is an example with Vitest: +Actions are automatically spied but type-wise, they are still the regular actions. In order to get the correct type, we must implement a custom type-wrapper that applies the `Mock` type to each action. **This type depends on the testing framework you are using**. Here is an example with Vitest: ```ts import type { Mock } from 'vitest'