Javascript 如何使两个对象相等并将此值返回到ng show
我有两个对象(日期)Javascript 如何使两个对象相等并将此值返回到ng show,javascript,angularjs,Javascript,Angularjs,我有两个对象(日期) {{vm.currentDate|date:'mediumDate'}} and {{vm.anotherDate|date:'mediumDate'}} 如何相等(如果相同)并将此操作的值发送到按钮中的指令 {{vm.currentDate|date:'mediumDate'}} and {{vm.anotherDate|date:'mediumDate'}} <button type="submit" ng-show="VALUE_FROM_OPERATIO
{{vm.currentDate|date:'mediumDate'}} and {{vm.anotherDate|date:'mediumDate'}}
如何相等(如果相同)并将此操作的值发送到按钮中的指令
{{vm.currentDate|date:'mediumDate'}} and {{vm.anotherDate|date:'mediumDate'}}
<button type="submit" ng-show="VALUE_FROM_OPERATION"></button>
检查它们是否相等,如下所示:
{{vm.currentDate|date:'mediumDate'}} and {{vm.anotherDate|date:'mediumDate'}}
+currentDate === +anotherDate
if(+currentDate===+anotherDate){console.log('its same date dude!');}的可能重复项