Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v4 #555

Closed
22 tasks
artalar opened this issue Apr 23, 2023 · 2 comments
Closed
22 tasks

v4 #555

artalar opened this issue Apr 23, 2023 · 2 comments
Milestone

Comments

@artalar
Copy link
Owner

artalar commented Apr 23, 2023

We plan to release a new major version each year. No heavy breaking changes, only improvements around some quirks of existed API. We found a way to hide ctx and make the code more natural. This is the most required feature and we glad to be able to implement it fast as possible. Many features of reatom/effects and reatom/async will be integrated to the core package for better performance and less complex realization, it will be allow you to use withCache for regular atoms and actions, which is unbelivable cool. But we will try to not change things a lot: atom, action, pipe, onChange, onCall will the same, as many other APIs.

Here is the list of notes what we should to change.

  • remove AtomCache from the third argument of onUpdate callback. Pass params to the third argument of onUpdate callback.
  • remove optional spy method from Ctx (it should have no any effect for existed code)
  • change ctx.spy(({ params, payload }) => ) to ctx.spy((params, payload) => )
  • some guarantees of uniqueness of names How to track names uniqueness? #556
  • do not call callback from the second argument of ctx.spy for atoms on initiate
  • prevent subscribe from onConnect to prevent connection stack
  • made return type of callSafely is void
  • throw an error if with* (mutable) operator applies multiple times
  • replace unstable_fn by something public and less hacky, maybe optional mock method?
  • drop AsyncOptions hooks to force onUpdate using for consistent codestyle
  • remove abortControllerAtom as a public property of AsyncAction coz in mostly internal thing, which behaviour could be not obvious for a user
  • use native throwIfAborted instead of ponyfil from the utils
  • withReducers should accept ctx by the first argument
  • remove ctx.get(callback) API and and explicit batch API or allow to delay updates to a next tick for autobatching
  • remove null variant from AtomCache['cause']
  • dataAtom.reset should return the last (not new) state, to use it for a rollback
  • move bind from reatom/lens to ... something else.
  • getRootCause should accept Ctx and the realisation should be just ctx.get(read => read(__root)!)
  • ctx.controller should be removed, the feature will be replaced with instence of CauseContext
  • infer error type from field validation (reatom/form)
  • remove after optional parameter from retry of withRetry
  • withRetry should wrap returned promise which shouldn't fail during retrying
@BANOnotIT
Copy link
Collaborator

BANOnotIT commented Apr 23, 2023

@artalar artalar added this to the 4.0 milestone May 26, 2023
@artalar artalar pinned this issue Jul 2, 2023
@artalar artalar unpinned this issue Jan 10, 2024
@artalar artalar pinned this issue Jan 10, 2024
@krulod krulod unpinned this issue Jan 10, 2024
@artalar artalar pinned this issue May 19, 2024
@artalar artalar unpinned this issue May 19, 2024
@artalar
Copy link
Owner Author

artalar commented May 19, 2024

This issue contains a list on minor changes, which is not so relevent anymore, as we want to change a little bit more: #841

@artalar artalar closed this as completed May 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants