I am not able to create a Javascript Date object (in Firefox) with 12-hour format time as a parameter to the Date constructor. I tried the following way:
new Date('2021-05-18 04:00 PM+05:30')
This works perfectly in Chrome but not in Firefox and Safari.
Can someone please help in creating a Date object without converting it to a 24-hour time format and which would work on all browsers?
 
     
    