You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@streampipes.apache.org by bo...@apache.org on 2023/01/02 18:46:17 UTC

[streampipes] 02/06: add linting to apidocs module (#877)

This is an automated email from the ASF dual-hosted git repository.

bossenti pushed a commit to branch chore/ui-linting-a
in repository https://gitbox.apache.org/repos/asf/streampipes.git

commit 561583842af41e913fa49c7a0e1e59b405e7183f
Author: bossenti <bo...@posteo.de>
AuthorDate: Mon Jan 2 19:28:54 2023 +0100

    add linting to apidocs module (#877)
---
 ui/.eslintignore                        |  1 -
 ui/.prettierignore                      |  1 -
 ui/src/app/apidocs/apidocs.component.ts | 31 ++++++++++++-------------------
 ui/src/app/apidocs/apidocs.module.ts    | 13 +++----------
 4 files changed, 15 insertions(+), 31 deletions(-)

diff --git a/ui/.eslintignore b/ui/.eslintignore
index 4f9c372fb..4d01bd8dc 100644
--- a/ui/.eslintignore
+++ b/ui/.eslintignore
@@ -22,7 +22,6 @@ projects
 src/app/_enums
 src/app/_guards
 src/app/_models
-src/app/apidocs
 src/app/app-asset-monitoring
 src/app/app-overview
 src/app/assets
diff --git a/ui/.prettierignore b/ui/.prettierignore
index e9b467842..3335f04e0 100644
--- a/ui/.prettierignore
+++ b/ui/.prettierignore
@@ -22,7 +22,6 @@ projects
 src/app/_enums
 src/app/_guards
 src/app/_models
-src/app/apidocs
 src/app/app-asset-monitoring
 src/app/app-overview
 src/app/assets
diff --git a/ui/src/app/apidocs/apidocs.component.ts b/ui/src/app/apidocs/apidocs.component.ts
index e3f94e5ff..f6a0a8074 100644
--- a/ui/src/app/apidocs/apidocs.component.ts
+++ b/ui/src/app/apidocs/apidocs.component.ts
@@ -19,27 +19,20 @@
 import { Component, ElementRef, OnInit } from '@angular/core';
 import SwaggerUI from 'swagger-ui';
 
-
 @Component({
-  selector: 'sp-apidocs',
-  templateUrl: './apidocs.component.html',
-  styleUrls: ['./apidocs.component.scss']
+    selector: 'sp-apidocs',
+    templateUrl: './apidocs.component.html',
+    styleUrls: ['./apidocs.component.scss'],
 })
 export class ApidocsComponent implements OnInit {
+    constructor(private el: ElementRef) {}
 
-  constructor(private el: ElementRef) {
-
-  }
-
-  ngOnInit(): void {
-    SwaggerUI({
-      url: '/streampipes-backend/api/openapi.json',
-      domNode: this.el.nativeElement.querySelector('.swagger-ui'),
-      deepLinking: false,
-      presets: [
-        SwaggerUI.presets.apis
-      ],
-    });
-  }
-
+    ngOnInit(): void {
+        SwaggerUI({
+            url: '/streampipes-backend/api/openapi.json',
+            domNode: this.el.nativeElement.querySelector('.swagger-ui'),
+            deepLinking: false,
+            presets: [SwaggerUI.presets.apis],
+        });
+    }
 }
diff --git a/ui/src/app/apidocs/apidocs.module.ts b/ui/src/app/apidocs/apidocs.module.ts
index 15dafa986..cc44fd6ad 100644
--- a/ui/src/app/apidocs/apidocs.module.ts
+++ b/ui/src/app/apidocs/apidocs.module.ts
@@ -30,17 +30,10 @@ import { ApidocsComponent } from './apidocs.component';
         CoreUiModule,
         CustomMaterialModule,
     ],
-    declarations: [
-        ApidocsComponent
-    ],
+    declarations: [ApidocsComponent],
     providers: [],
-    exports: [
-        ApidocsComponent
-    ]
+    exports: [ApidocsComponent],
 })
 export class ApidocsModule {
-
-  constructor() {
-  }
-
+    constructor() {}
 }