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

domain api. Rename event, store, effect to createEvent, createStore, createEffect #186

Closed
belozer opened this issue Aug 21, 2019 · 2 comments
Closed

Comments

@belozer
Copy link
Contributor

@belozer belozer commented Aug 21, 2019

event.
Base api for create event - createEvent, but in domain domain.event....
but hook named as domain.onCreateEvent....

store.
Base api for create store - createStore, but in domain domain.store....
but hook named as domain.onCreateStore....

effect.
Base api for create store - createEffect, but in domain domain.effect....
but hook named as domain.onCreateEffect....

Proposal

Rename domain.event to domain.createEvent
Rename domain.store to domain.createStore
Rename domain.effect to domain.createEffect
Mark domain.event and domain.store, domain.effect as deprecated

OR
Rename base api createEvent -> event, createStore -> store, createEffect -> effect
and mark createEvent, createStore, createEffect as deprecated

@belozer belozer added the RFC label Aug 21, 2019
@belozer belozer changed the title domain api. Change event, store to createEvent, createStore domain api. Rename event, store to createEvent, createStore Aug 21, 2019
@belozer belozer changed the title domain api. Rename event, store to createEvent, createStore domain api. Rename event, store, effect to createEvent, createStore, createEffect Aug 21, 2019
@zerobias

This comment has been minimized.

Copy link
Owner

@zerobias zerobias commented Aug 21, 2019

I'm agree with renaming domain.* to domain.create* 👍

Replacing createEvent with event is not convenient, as event is common name for events itself

New aliases can be added here

@zerobias

This comment has been minimized.

Copy link
Owner

@zerobias zerobias commented Nov 26, 2019

Implemented in effector 20.7.0

@zerobias zerobias closed this Nov 26, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.