network_request 0.3.0
network_request: ^0.3.0 copied to clipboard
A powerful and comprehensive Dart package for simplifying HTTP requests and interacting with RESTful APIs
0.3.0 #
Breaking Change #
- The Request that triggered the Re-authenticate flow passed in tryToReauthenticate to make better decision
- How to resolve:
Previously, you may have implemented.
Now, update your method to:@override Future<bool> tryToReauthenticate({dynamic client}) async { // ... your logic }
@override Future<bool> tryToReauthenticate({required Request request, dynamic client}) async { // ... your logic }
- How to resolve:
0.2.2 #
- Request headers override auth header
- Status code added in error logs if available
0.2.1 #
- Correct Error logs
0.2.0 #
- Made Decoding Error more explanatory with stack trace
- Added support for aborting requests. Introduced in http >= 1.5.0
0.1.1 #
- Made wasm compatible
0.1.0 #
New Features #
- Successful response status codes made customizable. Defaults to 200-299.
- More information given to decodeError.
- Examples improved
Breaking Change #
-
Typo correction: The property
unautherizedStatusCode
has been renamed tounauthorizedStatusCode
.- Action required: If you have overridden this property in your custom
NetworkRequest
subclasses, update your code to use the new name. If not, no changes are needed.
- Action required: If you have overridden this property in your custom
-
headers
field inNetworkRequest
made private to avoid any unintended behaviour. It is no longer accessible for subclasses. -
decodeError
parameters have changed to send CapturedResponse instead of dynamic.- How to resolve:
Previously, you may have implemented.
Now, update your method to:Exception? errorDecoder(dynamic data) { // ...your logic here }
This change gives you access to the full response object, so useException? errorDecoder(CapturedResponse response) { var data = response.body; // ...your logic here }
response.body
to access the data as before.
- How to resolve:
0.0.4+1 #
- Readme updated to highlight the
call
method & CustomizabilityNetworkRequest
of explained
0.0.4 #
- Download and Upload progress callback added
0.0.3+2 #
- Topics added in description.
0.0.3+1 #
- Readme updated.
0.0.3 #
- http updated to
1.4.0
. - Readme updated.
0.0.2 #
- Readme updated.
0.0.1 #
- Initial version.