swagger-ui icon indicating copy to clipboard operation
swagger-ui copied to clipboard

Pass data directly

Open manasarora119 opened this issue 7 years ago • 1 comments

Is it possible to pass data directly , rather than passing json url in URL ,

I want to pass json directly to UI Bundle

manasarora119 avatar Apr 15 '19 05:04 manasarora119

Use the spec parameter:

const ui = SwaggerUIBundle({
  "dom_id": "#swagger-ui",
  spec: {
    "swagger": "2.0",
    "info": { ... },
    "paths": { ... },
    ...
  },
  ...
})

hkosova avatar Apr 15 '19 14:04 hkosova