chore: initial import for test contour with k3s CI
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
import { Controller } from 'stimulus';
|
||||
import "swagger-ui-dist/swagger-ui.css"
|
||||
|
||||
/*
|
||||
* This is an example Stimulus controller!
|
||||
*
|
||||
* Any element with a data-controller="default" attribute will cause
|
||||
* this controller to be executed. The name "default" comes from the filename:
|
||||
* default_controller.js -> "default"
|
||||
*
|
||||
* Delete this file or adapt it for your use!
|
||||
*/
|
||||
export default class extends Controller {
|
||||
connect() {
|
||||
var SwaggerUIBundle = require('swagger-ui-dist').SwaggerUIBundle;
|
||||
var wrap = this.element;
|
||||
|
||||
SwaggerUIBundle({
|
||||
url: "/api/swagger.json",
|
||||
dom_id: '#swagger-ui'
|
||||
});
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user