React.NET
React.NET copied to clipboard
code is not working date ,title,amount is not defined error is showing but it is already defined
import React from 'react'; import Video from './components/Video'; function App() {
let subscription = [ { id: "1", date: new Date('2021', '03', '15'), Title: "Monthly Subscription", amount: "1325.60"
},
{
id: "2",
date: new Date('2021', '05', '15'),
Title: "Annually Subscription",
amount: "1215.60"
},
{
id: "3",
date: new Date('2021', '02', '15'),
Title: "Quaterly Subscription",
amount: "1250.60"
}
]; let date = new Date('2021', '08', '15'); let Title = "Monthly Subscription"; let Amount = '125.50';
return ( <> <Video passeddate={subscription[0].date} passedtitle={subscription[0].Title} passedamount={subscription[0].amount} /> <Video passeddate={subscription[1].date} passedtitle={subscription[1].Title} passedamount={subscription[1].amount} /> <Video passeddate={subscription[2].date} passedtitle={subscription[2].Title} passedamount={subscription[2].amount} /> </> ); } export default App;