React-Props-and-Expressions Flashcards

1
Q

What are props in React?

A

Props are the information that you pass to a JSX tag

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

How do you declare and access props in a component?

A

You can declare props by passing them as arguments of the component

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

How do you pass props to a component?

A

Add them to the JSX tag like you would with HTML attributes

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

How do you write JavaScript expressions in JSX?

A

The JavaScript expression must be set inside a pair of curly braces

How well did you know this?
1
Not at all
2
3
4
5
Perfectly