msw-dev-tool 1.1.10 → 1.1.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,9 +1,20 @@
1
1
  # Install
2
2
 
3
+ - npm:
3
4
  ```bash
4
5
  npm i msw-dev-tool --save-dev
5
6
  ```
6
7
 
8
+ - yarn:
9
+ ```bash
10
+ yarn add msw-dev-tool --dev
11
+ ```
12
+
13
+ - pnpm:
14
+ ```bash
15
+ pnpm add msw-dev-tool --save-dev
16
+ ```
17
+
7
18
  ## Peer Dep
8
19
 
9
20
  These dependencies are assumed to already exist in your project.
@@ -15,8 +26,11 @@ If not, please install it.
15
26
  "zustand": "^5.0.2",
16
27
  "msw": "^2.7.0"
17
28
  ```
29
+ - [install msw](https://mswjs.io/docs/getting-started)
30
+ - [install zustand](https://zustand.docs.pmnd.rs/getting-started/introduction#installation)
18
31
 
19
32
  # Usage
33
+ > Please look forward to the official document. I will tell you how to use it in more detail.
20
34
 
21
35
  ## UI
22
36
 
@@ -40,14 +54,15 @@ function App() {
40
54
  ```typescript
41
55
  import { setupWorker } from "msw/browser";
42
56
  import { handlers } from "./handlers";
43
- import { initMSWDevTool } from "msw-dev-tool";
57
+ import { setupDevToolWorker } from "msw-dev-tool";
44
58
 
45
- // Wrap worker init logic with `initMSWDevTool` middleware.
46
- export const worker = initMSWDevTool(setupWorker(...handlers));
59
+ // use setupDevToolWorker instead of setupWorker from msw.
60
+ export const worker = setupDevToolWorker(...handlers);
47
61
 
48
62
  ```
49
63
 
50
- # Structure
64
+
65
+ # ProjectStructure
51
66
 
52
67
  This project uses pnpm workspaces.
53
68