date parsing is broken on linux

This patch creates a thin wrapper in js and will do the parsing there instead.