14 Commits

Author SHA1 Message Date
Daishi Kato
2bc4de3c60
feat(middleware): devtools to patch api.setState with namedSet and fix middleware types (#634)
* wip: patch api.setState with devtools middleware

* wip: middleware type tests

* fix middleware types

* oh, that was it!

* fix a test, add comments
2021-11-04 07:30:38 +09:00
Daishi Kato
6f95f128bf
fix(tests): add #632 example and improve middleware types tests (#633)
* fix(tests): add #632 example

* update #632 example in test

* update #632 example in test again

* add #631 example in test

* add a link to middleware type test in readme

* change/simplify middleware type test

* comment on same line

* fix: middleware test for single subscribeWithSelector

* empty commit

* link to immer reference implementation in readme

* update readme
2021-11-03 18:02:44 +09:00
Anatole Lucet
8665dd6cfe
feat(middleware): add persist api (#624)
* feat(persist middleware): add api

* workaround types

* add comment

Co-authored-by: daishi <daishi@axlight.com>
2021-11-02 20:46:55 +09:00
Daishi Kato
3889419fb5
chore(tests): more typing example with subscribeWithSelector (#621) 2021-11-02 20:45:55 +09:00
Daishi Kato
7e94455d27
fix(middleware): simplify middleware types and allow explicit typing (#617)
* chore(tests): add a use case combining many middleware

* simplify middleware types and allow explicit typing reverting some of #601

* fix context tests

* prettier

* refine middleware type test for more coverage and readability
2021-10-30 09:23:25 +09:00
Daishi Kato
ad318f3ebd
fix(middleware): types and devtools (#613)
* fix(middleware): types and devtools

* a fix

* make combine clean and always accept 3rd name arg

* revert fn name
2021-10-27 00:18:58 +09:00
Daishi Kato
ae888bdb05
fix(tests): immer middleware type test (#610)
* fix(tests): immer middleware type test

* empty commit

* sync with #613
2021-10-27 00:04:41 +09:00
Daishi Kato
37ff965563
feat(middleware): subscribeWithSelector middleware (#603)
* feat(middleware): subscribeWithSelector middleware, deprecating the core feature

* update readme

* update readme
2021-10-21 22:51:10 +09:00
Daishi Kato
5f5527d590
fix(types): Rename from UseStore to UseBoundStore (#595) 2021-10-21 18:02:50 +09:00
Daishi Kato
10cb45c201
feat(types): better middleware support (#601)
* feat(types): better middleware support

* some more trial

* some more trial

* Revert "some more trial"

This reverts commit c54bf7cb75faa58e6df4325679ea5f815b594d01.

* some more trial

* some more trial

* some more trial

* some more trial

* Revert "some more trial"

This reverts commit 3aef9e229a54f18a901a1aea557cb05b46e8f2ab.

* some more trial

* Revert "some more trial"

This reverts commit fce0cb4c3e012adb35e5240e64d31cde3f7790f8.

* some more trial

* some more trial

* some more trial

* some more trial

* add redux middleware type test

* fix with type alias

* add devtools and redux combination test

* combine to support named set

* remove duplicated types
2021-10-21 17:51:24 +09:00
Daishi Kato
ae86695c44
refactor(test): use aliases (#571) 2021-09-29 00:55:12 +09:00
marcoSven
bbd3793328
Allow optional REDUX DEVTOOLS "options" object (#540)
* Allow optional REDUX DEVTOOLS "options" object

## Why is this change needed?
Unable to display Maps/Sets

## How does it address the issue?
optional serialize date, regex, undefined, nan, infinity,
error, symbol, map & set

## breaking change prev "prefix" option
prefix?: string -> options?: { name?: string }

https://github.com/zalmoxisus/redux-devtools-extension/blob/master/docs/API/Arguments.md#serialize

https://github.com/pmndrs/zustand/issues/249

* backward compatible with "prefix" store name option

* Update readme.md
2021-08-26 22:53:40 +09:00
Daishi Kato
e47ea038fd
chore: update eslintrc and use react-jsx (#531) 2021-08-15 19:44:06 +09:00
Dương Tấn Huỳnh Phong
836aeaeccd
make type NamedSet compatible with type SetState (#441) 2021-06-20 22:33:29 +09:00