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

made add form for movie list #1908

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

Conversation

sintax1s
Copy link

Copy link

@ivaZaiets ivaZaiets 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! I didn't see mistakes. I think your code look awesome!

Copy link

@polosanya polosanya left a comment

Choose a reason for hiding this comment

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

Almost perfect!

Comment on lines 14 to 20
// #region state
const [title, setTitle] = useState('');
const [description, setDescription] = useState('');
const [imgUrl, setImgUrl] = useState('');
const [imdbUrl, setImdbUrl] = useState('');
const [imdbId, setImdbId] = useState('');
// #endregion

Choose a reason for hiding this comment

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

Region comments are actually redundant here but it's up to you

Comment on lines 39 to 43
setTitle('');
setDescription('');
setImgUrl('');
setImdbUrl('');
setImdbId('');

Choose a reason for hiding this comment

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

Would be great to create a separate function for resetting

Comment on lines 60 to 62
onChange={(value: string): void => {
setTitle(value);
}}

Choose a reason for hiding this comment

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

Suggested change
onChange={(value: string): void => {
setTitle(value);
}}
onChange={setTitle}

Can be simplified a lot. Fix all cases

@sintax1s sintax1s requested a review from polosanya October 22, 2023 16:13
Copy link

@StasSokolov1 StasSokolov1 left a comment

Choose a reason for hiding this comment

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

Looks good to me, i'm approving it🔥

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.

4 participants