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

solution #1846

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

solution #1846

wants to merge 1 commit into from

Conversation

Kozubowicz
Copy link

Copy link

@Zibi95 Zibi95 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 💯 Left some comments for future reference.

Comment on lines +18 to +20
const getTabContent = () => {
return tabs.find(tab => tab.id === selectedTabId)?.content;
};
Copy link

Choose a reason for hiding this comment

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

This function is redundant. You have already filtered out the selectedTab above this code in line 16.

Comment on lines +22 to +24
const onTabSelected = (tab: Tab) => {
setSelectedTabId(tab.id);
};
Copy link

Choose a reason for hiding this comment

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

Use destructuring whenever you can.

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