🤑 Join the Treehouse affiliate program and earn 25% recurring commission!

New No-Code Track! 🚀start learning today!

🌟 Dreaming of a bright future? 🎓 Ask about the Treehouse Scholarship program! 🚀

✨ Earn college credits in Cybersecurity, JS, HTML, CSS and Python

  • Treehouse Logo
  • Plans
    Chevron
    • For Individuals
    • For Businesses
    • For Schools
    • For Libraries
    • For Military
  • Library
    Chevron
    • All Courses
    • Tracks
    • College Credit
  • Techdegree
    Chevron
    • Overview
    • Front End Development
    • Full Stack JavaScript
    • Data Analysis
    • UX Design
    • Python
  • Community
    Chevron
    • Code Adventures
    • Discord
    • Forum
    • Success Stories
    • Treehouse Links
    • 100 Days of Code
  • Resources
    Chevron
    • Career Toolbox
    • CodeForward
    • Free Treehouse Near Me
    • Jobs
    • Blog
    • Support
    • About
  • For Individuals For Businesses For Schools For Libraries For Military
  • All Courses Tracks College Credit
  • Overview Front End Web Development Full Stack JavaScript Python Development Data Analysis UX Design
  • Code Adventures Discord Forum Success Stories Treehouse Links 100 Days of Code
  • Career Toolbox CodeForward Free Treehouse Near Me Jobs Blog Support About
  • Sign In
  • Free Trial
Instagram Twitter Facebook YouTube LinkedIn
    • Newest
      • Newest
      • Active
      • Unanswered
      • Featured
    • All Topics
      • All Topics
      • • General Discussion
      • • AI
      • • Android
      • • APIs
      • • Coding for Kids
      • • College Credit
      • • Computer Science
      • • CSS
      • • Data Analysis
      • • Databases
      • • Design
      • • Development Tools
      • • Digital Literacy
      • • Game Development
      • • Go Language
      • • HTML
      • • Java
      • • JavaScript
      • • Learning Resources
      • • Machine Learning
      • • No-Code
      • • PHP
      • • Professional Growth
      • • Python
      • • Quality Assurance
      • • React
      • • Ruby
      • • Security
      • • Swift
  • Joshua Ouma
    Joshua Ouma
    20,865 Points

    Why must we call props.removePlayer(props.id) inside an anonymous function for the remove button to work?

    Posted December 1, 2021 4:14pm by Joshua Ouma
    Joshua Ouma
    20,865 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    2 Answers

  • Joshua Gage
    Joshua Gage
    4,010 Points

    removePlayer function not working

    Posted July 2, 2021 8:33pm by Joshua Gage
    Joshua Gage
    4,010 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    1 Answer

  • HONGYUAN QIU
    HONGYUAN QIU
    1,113 Points

    Why do we use the anonymous function for the removePlayer in Player?

    Posted June 11, 2021 6:57pm by HONGYUAN QIU
    HONGYUAN QIU
    1,113 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    2 Answers

  • dodders
    seal-mask
    .a{fill-rule:evenodd;}techdegree seal-36
    dodders
    Python Development Techdegree Graduate 38,680 Points

    Why does Guil create the handleRemovePlayer under App and not Player?

    Posted May 3, 2021 5:20pm by dodders
    .a{fill-rule:evenodd;}techdegree seal-36
    dodders
    Python Development Techdegree Graduate 38,680 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    3 Answers

  • Ayman Elash
    Ayman Elash
    3,221 Points

    A clear example on prevState ?

    Posted March 27, 2021 8:42pm by Ayman Elash
    Ayman Elash
    3,221 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    3 Answers

  • L W
    L W
    6,234 Points

    around 03:20 why is it {player.id} instead of {this.state.player.id} since player is inside of a state?

    Posted August 15, 2020 2:51am by L W
    L W
    6,234 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    1 Answer

  • Ewerton Luna
    seal-mask
    .a{fill-rule:evenodd;}techdegree seal-36
    Ewerton Luna
    Full Stack JavaScript Techdegree Graduate 24,031 Points

    Why does he passes a id prop to the Player component if there's already a key prop that could be used instead?

    Posted February 25, 2020 2:53pm by Ewerton Luna
    .a{fill-rule:evenodd;}techdegree seal-36
    Ewerton Luna
    Full Stack JavaScript Techdegree Graduate 24,031 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    1 Answer

  • Joseph Butterfield
    seal-mask
    .a{fill-rule:evenodd;}techdegree seal-36
    Joseph Butterfield
    Full Stack JavaScript Techdegree Graduate 16,430 Points

    How do I console.log() inside of a Class?

    Posted February 6, 2020 9:21pm by Joseph Butterfield
    .a{fill-rule:evenodd;}techdegree seal-36
    Joseph Butterfield
    Full Stack JavaScript Techdegree Graduate 16,430 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    1 Answer

  • fairest
    seal-mask
    .a{fill-rule:evenodd;}techdegree seal-36
    fairest
    Full Stack JavaScript Techdegree Graduate 19,303 Points

    Why mention 'What's New in React 16' at the end of the course?!?!

    Posted January 14, 2020 11:16pm by fairest
    .a{fill-rule:evenodd;}techdegree seal-36
    fairest
    Full Stack JavaScript Techdegree Graduate 19,303 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    1 Answer

  • Jay McCormick
    Jay McCormick
    6,646 Points

    Anonymous Function in OnClick

    Posted December 3, 2019 8:09pm by Jay McCormick
    Jay McCormick
    6,646 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    1 Answer

  • Felix Ding
    Felix Ding
    5,144 Points

    How come we don't have to bind thisArg in the onClick event for remove player?

    Posted August 5, 2019 6:41am by Felix Ding
    Felix Ding
    5,144 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    1 Answer

  • Gremyko Coleman
    Gremyko Coleman
    9,756 Points

    How would we create the handleRemovePlayer function to the Player, component, if the player componen was a class instead

    Posted May 22, 2019 4:14am by Gremyko Coleman
    Gremyko Coleman
    9,756 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    1 Answer

  • Gremyko Coleman
    Gremyko Coleman
    9,756 Points

    handleRemovePlayer function

    Posted May 20, 2019 5:31am by Gremyko Coleman
    Gremyko Coleman
    9,756 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    2 Answers

  • Zijun Liao
    Zijun Liao
    13,409 Points

    handleRemovePlayer binding

    Posted March 6, 2019 12:53am by Zijun Liao
    Zijun Liao
    13,409 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    1 Answer

  • jlampstack
    jlampstack
    23,932 Points

    handleRemovePlayer() function ... naming convention???

    Posted February 21, 2019 11:44am by jlampstack
    jlampstack
    23,932 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    1 Answer

  • Truman Smith
    seal-mask
    .a{fill-rule:evenodd;}techdegree seal-36
    Truman Smith
    Full Stack JavaScript Techdegree Graduate 17,901 Points

    How is score preserved after a player is removed?

    Posted January 2, 2019 6:37am by Truman Smith
    .a{fill-rule:evenodd;}techdegree seal-36
    Truman Smith
    Full Stack JavaScript Techdegree Graduate 17,901 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    2 Answers

  • brevans26
    brevans26
    15,198 Points

    p => p.id !== id

    Posted November 7, 2018 2:11pm by brevans26
    brevans26
    15,198 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    2 Answers

  • Sonya Trachsel
    Sonya Trachsel
    13,674 Points

    Getting an error "props.removePlayer isn't a function"

    Posted November 2, 2018 7:26pm by Sonya Trachsel
    Sonya Trachsel
    13,674 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    1 Answer

  • Otto linden
    Otto linden
    5,857 Points

    Is it only me that have no id what he is talking about? xD

    Posted October 15, 2018 6:48pm by Otto linden
    Otto linden
    5,857 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    8 Answers

  • kenweed
    kenweed
    12,156 Points

    I could not Delete Players, what am I missing?

    Posted September 30, 2018 11:11pm by kenweed
    kenweed
    12,156 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    3 Answers

  • Ceil-Ian Maralit
    seal-mask
    .a{fill-rule:evenodd;}techdegree seal-36
    Ceil-Ian Maralit
    Front End Web Development Techdegree Graduate 19,434 Points

    What is wrong with my code?

    Posted September 30, 2018 10:54am by Ceil-Ian Maralit
    .a{fill-rule:evenodd;}techdegree seal-36
    Ceil-Ian Maralit
    Front End Web Development Techdegree Graduate 19,434 Points
    • JavaScript
    • React Basics (2018)
    • Understanding State
    • Remove Items From State

    3 Answers

Posting to the forum is only allowed for members with active accounts.
Please sign in or sign up to post.

    Treehouse

  • About
  • Blog
  • Careers
  • Community
  • Stories
  • Shop
  • Contact
  • Gift Card

See Full Catalogue

Techdegree

  • Front End Web Development
  • Full Stack JavaScript
  • Python Development
  • Data Analysis
  • UX Design

Tracks

  • Learn to Code for Beginners
  • Beginning Python
  • Beginning SQL
  • Beginning Java
  • ...see more

Courses

  • JavaScript Basics
  • Intro to HTML & CSS
  • Python Basics
  • CSS Layout
  • ...see more

Explore

  • Plans
  • Affiliates
  • Perks
  • Free Treehouse Near Me
  • Treehouse for Libraries
  • Treehouse for Businesses
  • Twitter
  • YouTube
  • Facebook
  • LinkedIn
  • Instagram
Terms & Conditions | Privacy

© 2025 Treehouse Island, Inc.