File tree 2 files changed +46
-0
lines changed 2 files changed +46
-0
lines changed Original file line number Diff line number Diff line change
1
+ # Subscription
2
+
3
+ ## One-Click Deploy
4
+
5
+ Deploy your own SWR project with Vercel.
6
+
7
+ [ ![ Deploy with Vercel] ( https://vercel.com/button )] ( https://vercel.com/new/clone?s=https://github.com/vercel/swr/tree/main/examples/subscription )
8
+
9
+ ## How to Use
10
+
11
+ Download the example:
12
+
13
+ ``` bash
14
+ curl https://codeload.github.com/vercel/swr/tar.gz/main | tar -xz --strip=2 swr-main/examples/storage-tab-sync
15
+ cd storage-tab-sync
16
+ ```
17
+
18
+ Install it and run:
19
+
20
+ ``` bash
21
+ yarn
22
+ yarn dev
23
+ # or
24
+ npm install
25
+ npm run dev
26
+ ```
27
+
28
+ ## The Idea behind the Example
29
+
30
+ Show how you could use SWR to synchronize localStorage values between tabs.
Original file line number Diff line number Diff line change
1
+ {
2
+ "name" : " subscription" ,
3
+ "private" : true ,
4
+ "license" : " MIT" ,
5
+ "dependencies" : {
6
+ "next" : " latest" ,
7
+ "react" : " latest" ,
8
+ "react-dom" : " latest" ,
9
+ "swr" : " latest"
10
+ },
11
+ "scripts" : {
12
+ "dev" : " next" ,
13
+ "start" : " next start" ,
14
+ "build" : " next build"
15
+ }
16
+ }
You can’t perform that action at this time.
0 commit comments