React JS Quiz
Home
Blog
Privacy Policy
Contact Us
React TypeScript Quiz
How do you mark a prop as optional in a TypeScript props type?
Report this question
Add a question mark after the prop name
Show Explanation
A question mark after the prop name marks it optional, such as label?: string.
Use optional before the component
Put the prop in CSS
Use an exclamation mark before the type
Next Question (6/20)