forked from Archives/Athou_commafeed
add api documentation page
This commit is contained in:
12
commafeed-client/src/pages/app/ApiDocumentationPage.tsx
Normal file
12
commafeed-client/src/pages/app/ApiDocumentationPage.tsx
Normal file
@@ -0,0 +1,12 @@
|
||||
import { Loader } from "components/Loader"
|
||||
import React, { Suspense } from "react"
|
||||
|
||||
export function ApiDocumentationPage() {
|
||||
// swagger-ui is very large, load only on-demand
|
||||
const SwaggerUI = React.lazy(() => import("swagger-ui-react"))
|
||||
return (
|
||||
<Suspense fallback={<Loader />}>
|
||||
<SwaggerUI url="swagger/swagger.json" />
|
||||
</Suspense>
|
||||
)
|
||||
}
|
||||
Reference in New Issue
Block a user