UNPKG

next-openapi-gen

Version:

Automatically generate OpenAPI 3.0 documentation from Next.js projects, with support for Zod schemas and TypeScript types.

18 lines (15 loc) 394 B
export const stoplightDeps = ["@stoplight/elements"]; export function StoplightUI(outputFile) { return ` "use client"; import { API } from "@stoplight/elements"; import "@stoplight/elements/styles.min.css"; export default function ApiDocsPage() { return ( <section style={{ height: "100vh" }}> <API apiDescriptionUrl="${outputFile}" /> </section> ); } `; }