Giter VIP home page Giter VIP logo

Comments (9)

Justineo avatar Justineo commented on September 26, 2024

npm ls vue-demi 看一下?

from vue-echarts.

bighhhh avatar bighhhh commented on September 26, 2024

npm ls vue-demi 看一下?

微信截图_20231102174437

from vue-echarts.

bighhhh avatar bighhhh commented on September 26, 2024

npm ls vue-demi 看一下?

关键还出了另一个一样的问题
微信截图_20231102174552
微信截图_20231102174631
这个地方也没有官方的判断,不知道为什么

from vue-echarts.

Justineo avatar Justineo commented on September 26, 2024

[email protected] 应该是已经解决了你上面说的那个问题的了。请提供一个最小化的复现,否则没有办法提供帮助。

from vue-echarts.

bighhhh avatar bighhhh commented on September 26, 2024

[email protected] 应该是已经解决了你上面说的那个问题的了。请提供一个最小化的复现,否则没有办法提供帮助。

我也看vue-demi代码了,index.cjs文件中是已经有判断了,但是index.mjs中是没有那段判断的,而我这编译完vue-charts后的文件里用的就是index.mjs的代码,请问下这个是我环境配置的问题吗?
微信截图_20231103095546

微信截图_20231103095324

from vue-echarts.

Justineo avatar Justineo commented on September 26, 2024

看看你的 vue 是不是解析到 cjs 版本去了。如果是的话可以在配置里面强行指定一下 esm 版本试一下。类似 #644 (comment)

from vue-echarts.

bighhhh avatar bighhhh commented on September 26, 2024

看看你的 vue 是不是解析到 cjs 版本去了。如果是的话可以在配置里面强行指定一下 esm 版本试一下。类似 #644 (comment)

// EXTERNAL MODULE: external {"commonjs":"vue","commonjs2":"vue","root":"Vue"}
var external_commonjs_vue_commonjs2_vue_root_Vue_ = webpack_require(3797);
;// CONCATENATED MODULE: ./node_modules/vue-echarts/node_modules/vue-demi/lib/index.mjs
我这编译后显示vue是引入的commonjs版本,但是vue-echarts的vue-demi却使用的mjs版本文件,不知道是哪里问题导致的
我另一个插件也用着vue-demi却没有这问题,把vue-echarts移除了就不报错了,
配置了
alias: {
vue$: 'vue/dist/vue.esm.js' // 将 'vue$' 映射到 vue.esm.js
}
也不行,是因为babel的问题吗

from vue-echarts.

bighhhh avatar bighhhh commented on September 26, 2024

// EXTERNAL MODULE: external {"commonjs":"vue","commonjs2":"vue","root":"Vue"}
var external_commonjs_vue_commonjs2_vue_root_Vue_ = webpack_require(3797);
;// CONCATENATED MODULE: ./node_modules/vue-echarts/node_modules/vue-demi/lib/index.mjs

// EXTERNAL MODULE: external {"commonjs":"vue","commonjs2":"vue","root":"Vue"}
var external_commonjs_vue_commonjs2_vue_root_Vue_ = webpack_require(3797);
;// CONCATENATED MODULE: ./node_modules/vue-echarts/node_modules/vue-demi/lib/index.mjs

根据上面代码来看应该是vue-echarts跟我的项目引入方式冲突?

from vue-echarts.

Heath1998 avatar Heath1998 commented on September 26, 2024

external

最后这么解决的?

from vue-echarts.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.