mirror of
https://github.com/grocy/grocy.git
synced 2025-10-14 17:24:07 +00:00
Finish API documentation and token auth (references #5)
This commit is contained in:
26
public/viewjs/openapiui.js
Normal file
26
public/viewjs/openapiui.js
Normal file
@@ -0,0 +1,26 @@
|
||||
function HideTopbarPlugin()
|
||||
{
|
||||
return {
|
||||
components: {
|
||||
Topbar: function () { return null }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
const swaggerUi = SwaggerUIBundle({
|
||||
url: Grocy.OpenApi.SpecUrl,
|
||||
dom_id: '#swagger-ui',
|
||||
deepLinking: true,
|
||||
presets: [
|
||||
SwaggerUIBundle.presets.apis,
|
||||
SwaggerUIStandalonePreset
|
||||
],
|
||||
plugins: [
|
||||
SwaggerUIBundle.plugins.DownloadUrl,
|
||||
HideTopbarPlugin
|
||||
],
|
||||
layout: 'StandaloneLayout',
|
||||
docExpansion: "list"
|
||||
});
|
||||
|
||||
window.ui = swaggerUi;
|
Reference in New Issue
Block a user