re: React Fragments VIEW POST

FULL DISCUSSION
 

Hi Sarah,
Great post. I never thought of doing an Input component before, so that was also a great addition skill beyond the Fragment explanation too.
Also I think if you look you see two things, one I believe is an error and the second is what I believe to be a best practice for usability.

  1. Your second last example uses props not this, yet it's a Class declaration. What's tongue-in-cheek cute about the oversight is that you caught it on your next example and used this.

  2. I believe Labels should enclose the input tag for usability reasons. Which if I'm right then it means that extra

    isn't necessary.

    Regardless even if I'm right about any of those this was as I've said an awesome and easy to follow Fragment article. I've read a few as I try to process and learn to develop better with React and yours is good.

    Have a great week!

 

Thanks Roger, I'm glad you like the post. Thanks also for pointing out the error. I used the input field solely for an explanation. Should use a better example next time.

 

Oh my no it was great. I'm just in the early stages of learning React so for me I loved your Input component and I was serious about replicating it in some form in my own work. I recognize you it's just an 'example', but does that also mean making each input into a component as you've done isn't a good idea?

Btw I tried to use your lesson yesterday and couldn't quite get it to work. Darn! I was so excited to try Fragments finally.

Again thank you for your article. Don't feel bad about your examples, they were very helpful, so in that context they were the perfect choices :)

code of conduct - report abuse