feat: Runtime type reflection #17
1 changed files with 5 additions and 0 deletions
|
@ -20,3 +20,8 @@ console.log($contains!(searchItem, "erwin", "tj"));
|
|||
|
||||
// OK, record the type of square:
|
||||
square.reflectedType = $$typeToString!<typeof square>();
|
||||
|
||||
type Expand<T> = T extends unknown ? { [K in keyof T]: T[K] } : never;
|
||||
type Out = Expand<Dependencies<'multiply', number>>;
|
||||
|
||||
console.log("Deps type is", $$typeToString!<Out>())
|
||||
|
|
Loading…
Add table
Reference in a new issue