request(OVERVIEW.getTopoLink, REQUEST_TYPE.POST,{subnetId:this.props.match.params.id}).then((res) => {
})
export function request(url, requestType, data) {
console.log("request",data)
console.log("request",url)
if(requestType === REQUEST_TYPE.GET){
return axios.get(url, {
params: {
...data
}
})
}else{
const config = {
headers: {
"Content-Type": "application/x-www-form-urlencoded"
},
transformRequest:[function(data) {
return isObject(data) && String(data) !== "[object File]" ? requestParams(data) : data;
}],
requestType: requestType,
// timeout: 10000,
};
return axios.post(url, data, config)
}
}
when you cycle through requests to get data in this way, you will find that the browser"s memory footprint is increasing a little bit. How to solve this situation? How to free memory