match values start or end dates in javascript
问题 I am facing an issue in javascript dates, i want to match slot dates comparing start_date or end_date. my component {this.state.data && this.state.data.length ? this.state.data .filter(data => { const date = new Date(data.start_date); const enddate = new Date(data.end_date); console.log(date); //start console.log(enddate); //end return date > prevDate && date < nextDate; }) .map(({ cust_full_name, start_date }, index) => ( <div class="row" key={index}> slot: {index + 1} <p>{start_date}</p> <p