FAQ: React Forms - Write an Input Event Handler

This community-built FAQ covers the “Write an Input Event Handler” exercise from the lesson “React Forms”.

Paths and Courses
This exercise can be found in the following Codecademy content:

Web Development

Learn ReactJS: Part II

FAQs on the exercise Write an Input Event Handler

Join the Discussion. Help a fellow learner on their journey.

Ask or answer a question about this exercise by clicking reply (reply) below!

Agree with a comment or answer? Like (like) to up-vote the contribution!

Need broader help or resources? Head here.

Looking for motivation to keep learning? Join our wider discussions.

Learn more about how to use this guide.

Found a bug? Report it!

Have a question about your account or billing? Reach out to our customer support team!

None of the above? Find out where to ask other questions here!

The ‘solution’ to this exercise is broken. To be validated correct, it requires code that is taught later in the unit.

According to the presented instructions, a student shouldn’t need to build a constructor, thereby setting userInput’s initial state and binding handleUserInput. They also shouldn’t have to either add a value prop to the Input component or modify what is between the <h1> tags.

As it exists, if you ‘pass’ this exercise, you can Alt+Enter through the following exercises that actually teach you what is required to finish the unit.

4 Likes

it’s still broken as is…

7 months later and it’s still broken? That’s really disappointing.

1 Like

This is still broken 2 and a half years later

2 Likes

:kissing_smiling_eyes::ok_hand:

Another outstanding example exercise. Money well spent.

How come we are adding the handleUserInput function to input.js and not a container file? Have I misunderstood container and presentational components?

@ object1641750260

No you haven’t, although I wouldn’t worry about it too much because the creator has already said the usage of components and containers isn’t that relevant anymore since we can use Hooks for the same thing.

Also, the exercise is still broken.

1 Like

Im still having problems today with this excersize. It’s asking me to write a function and then not accepting it…When I check the solution it wants to revert back to the original state the file is in with a function that has already been defined (this is already the solution they are asking you to type).

So far the whole React course has been a bad experience for learning it seems very messy and confusing…

2 Likes