【发布时间】:2018-03-28 05:58:23
【问题描述】:
我不明白为什么我发现的所有示例都适用于这样的 json 请求:
d3.json("file.json", function(data){
..do something with data
});
..但是当我必须实现它时,我不得不使用:
d3.json( "file.json", function(data){}).then(function(data){
..do something with data
)};
那里发生了什么? 我正在使用节点运行实时服务器。
【问题讨论】:
-
Pssst你用了多长时间才注意到你的回调函数没有被使用?
标签: javascript json d3.js