how to write a date type in typescript code example Example: types date typescript const date: Date = new Date();