regexp in typescript types

The solution for “regexp in typescript types” can be found here. The following code will assist you in solving the problem.

type MarkerTime =`${number| ”}${number}:${number}${number}`

let a: MarkerTime = “0-00” // error
let b: MarkerTime = “0:00” // ok
let c: MarkerTime = “09:00” // ok

Thank you for using DeclareCode; We hope you were able to resolve the issue.

More questions on [categories-list]

0
inline scripts encapsulated in