I am using the NOAA API to return tide data for a given location. When I get the date/time info back (array with predictions.t) , it maps directly to a field in a grid using {{prediction.t}}. (t=date & time).
I want to reformat that from UTC format (I have the TS code for that), but I cannot figure out where to put it. There is no output mapping as the API return values go straight to a field. The return data is usually three or four dates with this format;
2023-07-17 00:28
2023-07-17 06:31
2023-07-17 13:10
2023-07-17 18:30
I'd like those to read:
July 17, 12:28 AM
July 17, 06:31 AM
July 17, 01:10 PM
July 17, 06:30 PM
Assuming that you want to pass the date as 2023-07-17 00:28 and receive date as July 17, 12:28 AM. Refer the code sample below for reference: