1.0.4 • Published 6 years ago

openapi-ui v1.0.4

Weekly downloads
2
License
MIT
Repository
gitlab
Last release
6 years ago

openapi-ui

build status test coverage npm version

Makes integrating a UI for your OpenAPI spec a breeze.

Examples

Express

const express = require("express");
const openApiUI = require("openapi-ui");

const app = express();

app.get("/docs", (req, res) => {
  const html = openApiUI.generateIndex({
    baseUrl: "/docs",
    title: "My API Docs",
    url:
      "https://raw.githubusercontent.com/OAI/OpenAPI-Specification/master/examples/v3.0/petstore.yaml"
  });

  res.send(html);
});

app.use("/docs", express.static(openApiUI.getAssetsPath()));

app.listen(3000);
1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.0

6 years ago