我有来自SQL查询{ date,text,desc},{,,,}的JSON,我需要比较日期(date1,date2,.)其他JS日期对象 (b1,b2,.)高效。问题是:目前我必须将每个JSON日期转换为JS date对象,然后才能比较它们,例如:else (date2->a2) then (a2 to>a2) then (a2 to b2)
else (daten->a
在我的react中,shouldComponentUpdate function,this.props和nextprops都有相同的属性,但它们不是equal.My代码: console.log(this.props); console.log('nextProps vs this.props:', nextProps === this.props);
console.log('this.props.style vs ne