Skip to content

Conversation

@SmotrovaLilit
Copy link

@SmotrovaLilit SmotrovaLilit commented Jul 4, 2018

Ht1 Smotrova Lilit

… firstName, lastName, email )

## HT1.2 Чистить форму после успешного добавления
@SmotrovaLilit SmotrovaLilit changed the title ## HT1.1 Создать форму для добавления человека, сохранять его в стор(… Ht1 Smotrova Lilit Jul 4, 2018

switch (type) {
case ADD_PERSON:
return state.update('items', (persons) => persons.concat([payload]))
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

лучше когда весь стейт immutable, а не только верхний уровень

form,
[authModule]: authReducer
form: form.plugin({
'add-person': (state, action) => {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

я бы в persons редюсере reset делал

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

Successfully merging this pull request may close these issues.

2 participants