Hi, Using the types helpers like Parameters and ReturnType we can extract types from function parameters and return values. For example:
declare function f1(arg: { a: number; b: string }): void;
// Extract the parameters type
type FunctParams = Parameters<typeof f1>;
// [arg: { a: number; b: string; }] // I need to read this
Could be possible to generate a json from FunctParams type? I mean without creating an instance of it
Any hints?