Difference between two dates in days jquery

In this post, we find a difference between two dates in days TypeScript File var timeStart= new Date(this.startDate).getTime(); var timeEnd = new Date(this.endDate).getTime(); var diff = timeEnd – timeStart; //in ms var milliseconds = timeStart > timeEnd ? timeStart % timeEnd : timeEnd % timeStart; var seconds = milliseconds / 1000; var minutes = seconds […]