Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Could not resolve "../node_modules/fmin/index.js #134

Open
Tenodec opened this issue Nov 29, 2021 · 3 comments
Open

Could not resolve "../node_modules/fmin/index.js #134

Tenodec opened this issue Nov 29, 2021 · 3 comments
Assignees

Comments

@Tenodec
Copy link

Tenodec commented Nov 29, 2021

使用@alifd/fusion-design-pro创建模板项目
yarn start
报错

ERR! Build failed with 2 errors: node_modules/venn.js/src/diagram.js:6:25: error: Could not resolve "../node_modules/fmin/index.js" node_modules/venn.js/src/layout.js:2:20: error: Could not resolve "../node_modules/fmin/index.js"

@ClarkXia
Copy link
Collaborator

ClarkXia commented Nov 29, 2021

问题有 venn.js 引起, 参考 issue benfred/venn.js#153 暂时可以通过以下方式配置:

{
  "vite": true,
+  "alias": {
+    "venn.js": "venn.js/build/venn.js"
+  },
  "plugins": [
    [
      "build-plugin-moment-locales",
      {
        "locales": [
          "zh-cn"
        ]
      }
    ],
    [
      "build-plugin-ignore-style",
      {
        "libraryName": "@alifd/next"
      }
    ]
  ]
}

@bindoon
Copy link
Member

bindoon commented Apr 18, 2022

npx create ice @alifd/fusion-design-pro
npm i
npm start
是这么启动吧,为啥我启动正常呢?

image

@chantAria
Copy link

问题有 venn.js 引起, 参考 issue benfred/venn.js#153 暂时可以通过以下方式配置:

{
  "vite": true,
+  "alias": {
+    "venn.js": "venn.js/build/venn.js"
+  },
  "plugins": [
    [
      "build-plugin-moment-locales",
      {
        "locales": [
          "zh-cn"
        ]
      }
    ],
    [
      "build-plugin-ignore-style",
      {
        "libraryName": "@alifd/next"
      }
    ]
  ]
}

顺利解决,顺带一提,是在根目录的build.json里

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants