Rebasely Beta: data may be purged

justintypescript-ultra-strict Public

Text · 8 lines · 285 B · at eb4a6ea

// A cast is an unchecked claim. `as const` is fine; anything else belongs in// a *.boundary.tsus file (see example 53).type User = { name: string };const user = JSON.parse('{"name":"ada"}') as User;const roles = ["admin", "user"] as const;console.log(user.name, roles.length);