D3.js 我应该如何使用d3请求?

D3.js 我应该如何使用d3请求?,d3.js,D3.js,我有一个react/d3项目,我正在使用axios.get检索通过express传递到本地url的数据。这是我的密码: return axios.get("http://localhost:3000/gadata") .then(response => { dispatch({ type: 'FETCH_DATA_SUCCESS', isFetching: false, data: response

我有一个react/d3项目,我正在使用
axios.get
检索通过express传递到本地url的数据。这是我的密码:

return axios.get("http://localhost:3000/gadata")
    .then(response => {
      dispatch({
            type: 'FETCH_DATA_SUCCESS',
            isFetching: false,
            data: response.data.rows
      });
    })

我希望能够使用
d3请求
,而不是axios。我应该如何重构我的代码?

你有过这样的经历吗?我正试图找到一个类似的解决方案。