@wiredcraft/miniprogram-sparrow
Advanced tools
Comparing version 0.0.3 to 0.0.4
@@ -6,4 +6,12 @@ # Change Log | ||
## [0.0.4](https://github.com/wiredcraft/miniprogram-tools/compare/@wiredcraft/miniprogram-sparrow@0.0.3...@wiredcraft/miniprogram-sparrow@0.0.4) (2021-03-08) | ||
**Note:** Version bump only for package @wiredcraft/miniprogram-sparrow | ||
## 0.0.3 (2021-03-02) | ||
**Note:** Version bump only for package @wiredcraft/miniprogram-sparrow |
{ | ||
"name": "@wiredcraft/miniprogram-sparrow", | ||
"version": "0.0.3", | ||
"version": "0.0.4", | ||
"description": "Experimental Recoil inspired state management", | ||
"repository": { | ||
@@ -38,3 +39,3 @@ "type": "git", | ||
}, | ||
"gitHead": "00ad976cfde3fce55b386befab3069165749da9f" | ||
"gitHead": "a4507047ca1575ffe9024128e5af057c857bc115" | ||
} |
@@ -0,9 +1,15 @@ | ||
## Install | ||
```bash | ||
yarn add @wiredcraft/miniprogram-sparrow | ||
``` | ||
## Usage | ||
```javascript | ||
# store/name.js | ||
// store/name.js | ||
import { atom } from "sparrow"; | ||
export const firstName = atom('Jack'); | ||
export const firstName = atom("Jack"); | ||
@@ -17,5 +23,5 @@ // the action | ||
```javascript | ||
# components/hello.js | ||
// components/hello.js | ||
import { write, behavior as sparrow } from "sparrow"; | ||
import { firstName, updateFirstName } from './store/name' | ||
import { firstName, updateFirstName } from "./store/name"; | ||
@@ -33,3 +39,3 @@ Component({ | ||
handleButtonOnTap() { | ||
updateFirstName('Rose') | ||
updateFirstName("Rose"); | ||
}, | ||
@@ -36,0 +42,0 @@ }, |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
7767
43