dates mostly working in JS