ECMAScript revision 5 adds native support for simplified ISO 8601 dates in the
Date.parse method, but some browsers currently on the market (Safari 5-, IE 8-, Firefox 3.6-) do not support it. This
is a simple shim for Date.parse that adds support for parsing ES5 simplified ISO 8601 strings to all browsers.
If you are attempting to parse date strings coming from non-ES5-conformant backends, please consider using the non-conformant edition.
- This library strictly implements the simplified ISO 8601 date time string format specified in the ES5 Errata (§18.104.22.168) and will not parse ISO 8601 variants that would otherwise be considered valid under ISO 8601:2004(E).
- Creating a new date using the
new Date(dateString)form will not be fixed by this shim.
Note: You must checkout using
git clone --recursive in order for unit tests to function.
© 2011 Colin Snover. MIT Licensed.