opendevs logo

Intro App

Solidify your knowledge of Props and States by solving this problem.
Merge State in useState

Krishna is working on a greet application. He is stuck in the middle of the greet application. He is not able to parse the props and construct the following message: Hello, my name is ${name} and I am ${age} years old. inside a p tag.

Props is passed as data object with name & age as key.

If no data is passed, the component should have default data props as {name: 'Dev11', age: 1}.

Solve this easy problem to earn  1  DevCoin image
Coding Area
opendevs logo
CoursesFAQsContact UsPrivacy PolicyTerms Of Service
Copyright © 2023 opendevs
Learn ● Develop ● Ace
All illustrations by Storyset