From af4beef6d797982c47f53c4475ffa4562ad9c18c Mon Sep 17 00:00:00 2001 From: MoritzWeber Date: Tue, 3 Dec 2024 13:34:45 +0100 Subject: [PATCH] perf(storybook): Disable Compodoc It wasn't used. --- frontend/.storybook/main.ts | 9 ++++++--- frontend/.storybook/preview.ts | 4 ---- frontend/.storybook/tsconfig.json | 1 - frontend/angular.json | 6 ++---- frontend/package.json | 1 - 5 files changed, 8 insertions(+), 13 deletions(-) diff --git a/frontend/.storybook/main.ts b/frontend/.storybook/main.ts index 0f2f946b44..4dd5664be4 100644 --- a/frontend/.storybook/main.ts +++ b/frontend/.storybook/main.ts @@ -20,12 +20,15 @@ const config: StorybookConfig = { name: '@storybook/angular', options: {}, }, - docs: { - autodocs: 'tag', - }, core: { disableTelemetry: true, enableCrashReports: false, + builder: { + name: '@storybook/builder-webpack5', + options: { + lazyCompilation: false, // lazyCompilation breaks Storycap + }, + }, }, }; export default config; diff --git a/frontend/.storybook/preview.ts b/frontend/.storybook/preview.ts index 33354f5471..01a8a3266b 100644 --- a/frontend/.storybook/preview.ts +++ b/frontend/.storybook/preview.ts @@ -8,17 +8,13 @@ import { importProvidersFrom } from '@angular/core'; import { MatDialogRef } from '@angular/material/dialog'; import { BrowserAnimationsModule } from '@angular/platform-browser/animations'; import { RouterModule } from '@angular/router'; -import { setCompodocJson } from '@storybook/addon-docs/angular'; import type { AngularRenderer, Preview } from '@storybook/angular'; import { applicationConfig } from '@storybook/angular'; import { ToastrModule } from 'ngx-toastr'; import { DecoratorFunction } from 'storybook/internal/types'; import { withScreenshot } from 'storycap'; -import docJson from '../documentation.json'; import { IconModule } from '../src/app/icon.module'; -setCompodocJson(docJson); - const preview: Preview = { parameters: { controls: { diff --git a/frontend/.storybook/tsconfig.json b/frontend/.storybook/tsconfig.json index 7d2b6089ed..4a0f48cdf5 100644 --- a/frontend/.storybook/tsconfig.json +++ b/frontend/.storybook/tsconfig.json @@ -5,7 +5,6 @@ "allowSyntheticDefaultImports": true, "resolveJsonModule": true }, - "exclude": ["../src/test.ts", "../src/**/*.spec.ts"], "include": ["./preview.ts", "../src/polyfills.ts", "../src/**/*.stories.ts"], "files": ["./typings.d.ts"] } diff --git a/frontend/angular.json b/frontend/angular.json index 5c75c43bda..31cf32e2c1 100644 --- a/frontend/angular.json +++ b/frontend/angular.json @@ -130,8 +130,7 @@ "configDir": ".storybook", "quiet": true, "browserTarget": "capellacollab:build:development", - "compodoc": true, - "compodocArgs": ["-e", "json", "-d", "."], + "compodoc": false, "port": 6006, "styles": [ ".storybook/styles.css", @@ -148,8 +147,7 @@ "options": { "configDir": ".storybook", "browserTarget": "capellacollab:build:storybook", - "compodoc": true, - "compodocArgs": ["-e", "json", "-d", "."], + "compodoc": false, "outputDir": "storybook-static", "styles": [ ".storybook/styles.css", diff --git a/frontend/package.json b/frontend/package.json index 1dc067a743..70aa50b3e9 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -51,7 +51,6 @@ "@angular/build": "^19.0.2", "@angular/cli": "~19.0.2", "@angular/compiler-cli": "~19.0.1", - "@compodoc/compodoc": "^1.1.26", "@eslint/js": "^9.16.0", "@storybook/addon-docs": "^8.4.6", "@storybook/addon-essentials": "^8.4.6",