Skip to content

Commit

Permalink
Updated pxth version (#139)
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexShukel authored Aug 26, 2023
1 parent 0b78fcc commit f5a61d6
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
"dependencies": {
"lodash": "^4.17.20",
"lodash-es": "^4.17.15",
"pxth": "^0.6.0",
"pxth": "^0.7.0",
"tiny-invariant": "^1.1.0"
},
"devDependencies": {
Expand Down
16 changes: 8 additions & 8 deletions pnpm-lock.yaml

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

4 changes: 2 additions & 2 deletions src/utils/useInterceptors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { deepGet, deepSet, getPxthSegments, isInnerPxth, Pxth, samePxth } from '
import invariant from 'tiny-invariant';

import { Stock } from '../hooks/useStock';
import { Observer } from '../typings';
import { Observer, SetStateAction } from '../typings';
import { StockProxy } from '../typings/StockProxy';

const shouldUseProxy = (proxy: StockProxy<unknown> | undefined, path: Pxth<unknown>) =>
Expand Down Expand Up @@ -57,7 +57,7 @@ export const useInterceptors = <T extends object>(stock: Stock<T>, proxy?: Stock
);

const interceptedSetValue = useCallback(
<V>(path: Pxth<V>, value: V) =>
<V>(path: Pxth<V>, value: SetStateAction<V>) =>
intercept(
proxy,
path as Pxth<unknown>,
Expand Down

0 comments on commit f5a61d6

Please sign in to comment.