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

реструктуризация Redux действий (restructure Redux actions) #35

Closed
aneurysmjs opened this issue Sep 10, 2019 · 2 comments
Assignees

Comments

@aneurysmjs
Copy link
Owner

все действия должны иметь одинаковую форму для целостности
(all actions should have the same shape for integrity)

@aneurysmjs
Copy link
Owner Author

aneurysmjs commented Sep 13, 2019

должен имеет метаданные
(it should have metadata)

{
 type: 'SOME_ACTION',
 meta: {
  ...metadata
 },
 payload: {
  ...data
 }
}

@aneurysmjs aneurysmjs self-assigned this Sep 13, 2019
aneurysmjs added a commit that referenced this issue Sep 22, 2019
improve Flow's error messaging by avoiding default value when typing StoreEnhancer<...> = devtools
|| compose since gives other kind of typing error which is not very helpful

improves #34, #35
@aneurysmjs
Copy link
Owner Author

Снимок экрана 2019-09-22 в 23 27 28

это такое сообщение об ошибке, которое появляется сейчас, оно жалуется на то, что некоторые действия имеют свойства "meta" или "payload", но другие не имеют.
(that's the kind of error message that appears now, it complains about that some actions has 'meta' or 'payload' properties but others don't)

@tayan-serna

aneurysmjs added a commit that referenced this issue Sep 23, 2019
arrange fetchProducts according to AsyncAction shape

improves #34, #35
aneurysmjs added a commit that referenced this issue Sep 23, 2019
arrange apiMiddleware to match payload actions for fetchProducts reducer

improves #34, #35
aneurysmjs added a commit that referenced this issue Sep 23, 2019
use 'meta' property since all is handled there

improves #34, #35
aneurysmjs added a commit that referenced this issue Sep 27, 2019
construct action object by conditionally taking payload and meta

improves #34, #35
aneurysmjs added a commit that referenced this issue Sep 27, 2019
aneurysmjs added a commit that referenced this issue Sep 27, 2019
aneurysmjs added a commit that referenced this issue Sep 29, 2019
also use makeActionCreator on fetchProducts

improves #35
aneurysmjs added a commit that referenced this issue Sep 29, 2019
create "ApiMetaType" on CommonType and use in ProductActionType

improves #34, #35
aneurysmjs added a commit that referenced this issue Sep 29, 2019
also use ActionType on FooterType

improves #34, #35
aneurysmjs added a commit that referenced this issue Sep 29, 2019
also use ActionType on CartActionType

improves #34, #35
aneurysmjs added a commit that referenced this issue Sep 29, 2019
move ApiMiddlewareType and import it from there, also remove useless $FlowIgnore comments

improves #34, #35
aneurysmjs added a commit that referenced this issue Oct 3, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant