Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

更新dio #15

Closed
wants to merge 8 commits into from
Closed

更新dio #15

wants to merge 8 commits into from

Conversation

Yumore
Copy link

@Yumore Yumore commented Mar 25, 2021

//添加拦截器
dio.interceptors.add(InterceptorsWrapper(onRequest: (options, handler) {
print("请求之前");
return handler.next(options);
}, onResponse: (response, hander) {
print("响应之前");
return hander.next(response);
}, onError: (DioError e, hanlder) {
print("错误之前");
handleError(e);
return hanlder.next(e);
}));
}

@xuexiangjys xuexiangjys closed this May 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants