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

Todo-App #1054

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open

Conversation

AvramenkoMarina
Copy link

Copy link

@volodymyr-soltys97 volodymyr-soltys97 left a comment

Choose a reason for hiding this comment

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

Good job 👍
Let's improve your code
You need to fix the input width
image
image

Also need to fix the eslint error for this line
image

Comment on lines 18 to 49
<a
href="#/"
className={classNames('filter__link', {
selected: filter === FilterTodos.All,
})}
data-cy="FilterLinkAll"
onClick={() =>
dispatch({ type: 'setFilterByStatus', payload: FilterTodos.All })
}
>
All
</a>

<a
href="#/active"
className={classNames('filter__link', {
selected: filter === FilterTodos.Active,
})}
data-cy="FilterLinkActive"
onClick={() =>
dispatch({ type: 'setFilterByStatus', payload: FilterTodos.Active })
}
>
Active
</a>

<a
href="#/completed"
className={classNames('filter__link', {
selected: filter === FilterTodos.Completed,
})}
data-cy="FilterLinkCompleted"

Choose a reason for hiding this comment

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

Use Object.values(your enum) and render these options with map() method

Copy link

@volodymyr-soltys97 volodymyr-soltys97 left a comment

Choose a reason for hiding this comment

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

Well done! 🔥

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