C3JS - Cannot read property 'category10' of undefined

后端 未结 3 1351
花落未央
花落未央 2020-12-15 16:35

I tried this c3.js code from jsfiddle (https://jsfiddle.net/varunoberoi/mcd6ucge) but it doesn\'t seem to work in my localhost.

I\'m using uniserver as my server. I

3条回答
  •  隐瞒了意图╮
    2020-12-15 17:01

    I solved the exact same JavaScript error on another project by downgrading from D3.js v4 (4.1.1) to v3 (3.5.17).

    It turns out that C3.js, as of July 2016, does not support D3.js v4:

    It definitely will not work as-is with [D3.js] 4.0. D3 v4 has a totally different namespace and is in no way backwards compatible. Updating to v4 is a very non-trivial task.

提交回复
热议问题