You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
13 lines
319 B
13 lines
319 B
import {isoSpecifier} from "./isoFormat"; |
|
import {utcParse} from "./defaultLocale"; |
|
|
|
function parseIsoNative(string) { |
|
var date = new Date(string); |
|
return isNaN(date) ? null : date; |
|
} |
|
|
|
var parseIso = +new Date("2000-01-01T00:00:00.000Z") |
|
? parseIsoNative |
|
: utcParse(isoSpecifier); |
|
|
|
export default parseIso;
|
|
|