quantum_fetch

Creator: coderz1093

Last updated:

0 purchases

quantum_fetch Image
quantum_fetch Images
Add to Cart

Description:

quantum fetch

quantum_fetch #
A module that uses powerful http library dio for network calls. You can directly start with already setup project or you can configure it the following way in your project.
Introduction #
quantum_fetch is a network module that has been created seperately for easily maintaining code for dio. The usage of this module is pretty simple.
class MyFetchConfig implements QuantumFetchConfig {
@override
String get baseUrl => 'https://api.github.com';
@override
String tokenPrefix = 'Bearer ';
@override
Future<String?> get token => Future.value("my_authrization_token");
@override
List<Interceptor> get interceptors => [];

@override
int connectTimeout = 8000;

@override
String contentType = "application/json";

@override
Map<String, String> get headers => {"myheader": "myheadervalue"};
}
final fetchConfig = MyFetchConfig();
final quantumClient = QuantumFetch(fetchConfig);
copied to clipboard
QuantumFetchConfig is part of project dependency, from which we use the baseUrl in our quantum_fetch.
Basic Usage #
final response = await quantumClient.get<User>("/user",decoder: User.fromJson);
print(response.success);
copied to clipboard

License

For personal and professional use. You cannot resell or redistribute these repositories in their original state.

Files In This Product:

Customer Reviews

There are no reviews.

Related Products

More From This Creator