js wrapped for Date ref