You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Angular18+Electron33中Storybook8.4.1启动失败求助

Angular 18 + Electron 33 环境下启动 Storybook 8.4.1 报错问题

在 Angular 18 / Electron 33 应用中安装 Storybook 8.4.1 后,执行命令 ng run angular-electron:storybook 启动时出现如下错误:

=> Failed to build the preview
TypeError [ERR_INVALID_ARG_TYPE]: The "paths[1]" argument must be of type string. Received an instance of Array

.storybook/main.ts 使用默认配置,Storybook 页面加载后持续处于加载状态无法完成初始化。即使移除所有插件和故事,问题仍然存在。

附 angular.json 中 Storybook 相关配置:

"storybook": {
          "builder": "@storybook/angular:start-storybook",
          "options": {
            "configDir": ".storybook",
            "browserTarget": "angular-electron:build",
            "compodoc": true,
            "compodocArgs": [
              "-e",
              "json",
              "-d",
              "."
            ],
            "port": 6006
          }
        },
        "build-storybook": {
          "builder": "@storybook/angular:build-storybook",
          "options": {
            "configDir": ".storybook",
            "browserTarget": "angular-electron:build",
            "compodoc": true,
            "compodocArgs": [
              "-e",
              "json",
              "-d",
              "."
            ],
            "outputDir": "dist/storybook/angular-electron"
          }
        }

内容的提问来源于stack exchange,提问作者Arco Voltaico

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.06.16 14:35:56