r/reactjs • • Jun 03 '18

Beginner's Thread / Easy Question (June 2018)

Hello! just helping out /u/acemarke to post a beginner's thread for June! we had over 270 comments in last month's thread! If you didn't get a response there, please ask again here! You are guaranteed a response here!

Soo... Got questions about React or anything else in its ecosystem? Stuck making progress on your app? Ask away! We’re a friendly bunch. No question is too simple.

The Reactiflux chat channels on Discord are another great place to ask for help as well.

Pre-empting the most common question: how to get started learning react?

You might want to look through /u/acemarke's suggested resources for learning React and his React/Redux links list. Also check out http://kcd.im/beginner-react.

32 Upvotes

537 comments sorted by

View all comments

Show parent comment

1

u/GeeeL Jun 30 '18

Thanks for the responses. It's a project I'm making for practice so can do anything.

It's a basic card component that I want to reuse as a preview when filling out the form, in a view all as a small card and on click will take you to the page with a large view and update/delete options. Just want the view-all page to have an onClick which will redirect to the single view.

I passed it down and used default props with an empty function. Maybe unclean wasn't the right word. I was just trying to keep the component from having a prop and logic for only one of it's usecases which isn't needed in the other cases.

Is this something that you will often do in react?