Forum Discussion

bsastre's avatar
Occasional Visitor
2 years ago

Swagger UI styles


I am trying to use swagger ui in an existing with stenciljs.

The swagger user interface is displaing right, but without any styles. 

I would like the user interface to have the basic styles.


This is my code:




import { Component, Host, h, Prop } from '@stencil/core';
import SwaggerUI from 'swagger-ui';

  tag: 'gx-launchpad-api',
  styleUrl: 'gx-launchpad-api.scss',
  shadow: false,
export class GxLaunchpadApi {
  swaggerContainer!: HTMLElement;

  @Prop() data: Object;

  componentDidLoad() {
      url: '',
      dom_id: '#swagger-ui',
      domNode: this.swaggerContainer,
      layout: 'BaseLayout', 
  render() {
    return (
        <div id="swagger-ui" ref={el => (this.swaggerContainer = el as HTMLElement)}></div>
        <article class="card"></article>


 any help would be much appreciated.


This is how it looks:


No RepliesBe the first to reply