diff --git a/constants/data.ts b/constants/data.ts index b4e005a..e6e1c22 100644 --- a/constants/data.ts +++ b/constants/data.ts @@ -355,4 +355,11 @@ export const typeScriptInterface = `export interface Root { id: number; title: string; completed: boolean; +} + +export interface Props { + /** The user's name */ + name: string; + /** Should the name be rendered in bold */ + priority?: boolean }`; diff --git a/pages/api/typescript-to-json-schema.ts b/pages/api/typescript-to-json-schema.ts index 58fd2f6..d234e86 100644 --- a/pages/api/typescript-to-json-schema.ts +++ b/pages/api/typescript-to-json-schema.ts @@ -9,7 +9,7 @@ export default (req: NextApiRequest, res: NextApiResponse) => { const filePath = tempy.writeSync(req.body, { extension: "ts" }); const config: Config = { path: filePath, - expose: "none", + expose: "all", jsDoc: "extended", type: "*" };