Skip to content

Commit

Permalink
feat(valtio): ✨ add ref、watch api and upgrades valtio (#11644)
Browse files Browse the repository at this point in the history
* feat(valtio): ✨ add ref、watch api and upgrades valtio

* build: 🔧 add lock
  • Loading branch information
Jokergga authored Sep 20, 2023
1 parent f28997e commit 422da05
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 8 deletions.
2 changes: 1 addition & 1 deletion examples/with-valtio/.umirc.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
export default {
plugins: ['@umijs/plugins/dist/valtio'],
mfsu: false,
valtio: {},
};
2 changes: 1 addition & 1 deletion libs/valtio/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
"test": "jest"
},
"dependencies": {
"valtio": "1.10.5"
"valtio": "1.11.2"
},
"publishConfig": {
"access": "public"
Expand Down
3 changes: 2 additions & 1 deletion libs/valtio/src/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
export { proxy, snapshot, subscribe, useSnapshot } from 'valtio';
export { proxy, ref, snapshot, subscribe, useSnapshot } from 'valtio';
export {
derive,
devtools as proxyWithDevtools,
Expand All @@ -9,6 +9,7 @@ export {
subscribeKey,
underive,
useProxy,
watch,
} from 'valtio/utils';

// TODO:
Expand Down
2 changes: 2 additions & 0 deletions packages/plugins/src/valtio.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ export {
derive,
underive,
useProxy,
ref,
watch,
} from '${libPath}';
`,
});
Expand Down
14 changes: 9 additions & 5 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 422da05

Please sign in to comment.