jinfang134 / vue-pipeline

A pipeline component like jenkins blue ocean plugin.
https://jinfang134.github.io/vue-pipeline/
MIT License
329 stars 69 forks source link

请问下在Vue3里面怎么使用这个组件呢?先pnpm安装、后import使用,然后启动会报错找不到文件,方便指导下吗?谢谢! #46

Open Erica666 opened 1 year ago

Erica666 commented 1 year ago

在main.ts 中import import VuePipeline from 'vue-pipeline';

async function bootstrap() { const app = createApp(App); app.use(VuePipeline); app.mount('#app'); }

报错信息: ERROR Failed to resolve import "./PipelineNode" from "node_modules.pnpm\registry.npmmirror.com+vue-pipeline@1.0.12\node_modules\vue-pipeline\src\components\Pipeline.vue". Does the file exist?

ERROR 11:12:36 [vite] Internal server error: Failed to resolve import "./PipelineNode" from "node_modules.pnpm\registry.npmmirror.com+vue-pipeline@1.0.12\node_modules\vue-pipeline\src\components\Pipeline.vue". Does the file exist? Plugin: vite:import-analysis File: C:/GitProject/moray-web/node_modules/.pnpm/registry.npmmirror.com+vue-pipeline@1.0.12/node_modules/vue-pipeline/src/components/Pipeline.vue 1 |
2 | import PipelineNode from "./PipelineNode"; | ^ 3 | import PipelineLine from "./PipelineLine"; 4 | import { Pipeline } from "./service"; at formatError (C:\GitProject\moray-web\node_modules.pnpm\registry.npmmirror.com+vite@2.9.15_less@4.1.3\node_modules\vite\dist\node\chunks\dep-689425f3.js:39080:46) at TransformContext.error (C:\GitProject\moray-web\node_modules.pnpm\registry.npmmirror.com+vite@2.9.15_less@4.1.3\node_modules\vite\dist\node\chunks\dep-689425f3.js:39076:19) at normalizeUrl (C:\GitProject\moray-web\node_modules.pnpm\registry.npmmirror.com+vite@2.9.15_less@4.1.3\node_modules\vite\dist\node\chunks\dep-689425f3.js:58360:26) at async TransformContext.transform (C:\GitProject\moray-web\node_modules.pnpm\registry.npmmirror.com+vite@2.9.15_less@4.1.3\node_modules\vite\dist\node\chunks\dep-689425f3.js:58509:57) at async Object.transform (C:\GitProject\moray-web\node_modules.pnpm\registry.npmmirror.com+vite@2.9.15_less@4.1.3\node_modules\vite\dist\node\chunks\dep-689425f3.js:39317:30) at async doTransform (C:\GitProject\moray-web\node_modules.pnpm\registry.npmmirror.com+vite@2.9.15_less@4.1.3\node_modules\vite\dist\node\chunks\dep-689425f3.js:50043:29)

kenail2002 commented 1 year ago

import PipelineNode from "./PipelineNode.vue";