Replies: 1 comment
-
Hi @fuz12, I've added a new method in You can update your pubspec.yaml file, this is what the new method looks like. class ApiService extends NyApiService {
ApiService({BuildContext? buildContext})
: super(
buildContext,
decoders: modelDecoders,
initDio: (Dio dio) {
return dio..httpClientAdapter = Http2Adapter(
ConnectionManager(idleTimeout: Duration(seconds: 10)),
);
}, Hope that helps |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
After creating instance Dio there is no way to define httpClientAdapter. Could you please add this option or allow creating own Dio at all.
Our plans are to switch to http2. We want to do this via package dio_http2_adapter.
Beta Was this translation helpful? Give feedback.
All reactions