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

Update TodoItems.js #3

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

Commits on May 16, 2023

  1. Update TodoItems.js

    Binding in Constructor: You are binding your class methods in the constructor, which is a common practice in class components. However, it might be more convenient and cleaner to use arrow functions for methods in your class. This way, you don't need to bind this context in the constructor.
    
    Prop Types: It's a good practice to define propTypes for your components. This helps with validation and makes sure that the props you're expecting are being passed in correctly.
    
    Destructuring Props: In the render method, you can destructure the props for cleaner code.
    
    Use const instead of var: In modern JavaScript, const or let is preferred over var due to their block scope.
    
    Semantic HTML: Use button for delete action as it is more semantic, and it can help with accessibility.
    ajinsunny authored May 16, 2023
    Configuration menu
    Copy the full SHA
    2cdccb3 View commit details
    Browse the repository at this point in the history