-
Notifications
You must be signed in to change notification settings - Fork 544
better_networking Package Creation #857
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
Conversation
should not be replaced by
|
pubspec.yaml
Outdated
@@ -14,6 +14,8 @@ dependencies: | |||
path: packages/apidash_core | |||
apidash_design_system: | |||
path: packages/apidash_design_system | |||
better_networking: | |||
path: packages/better_networking |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should not be directly added here.
better_networking will flow into apidash via apidash_core.
Hi @animator, better_networking has been exported from apidash_code and all imports have been fixed. |
Kindly make only necessary changes in the PR. |
Use GitHub Desktop https://desktop.github.com/download/ |
7830a14
to
1b64d05
Compare
have reverted them. changed file count is down. vscode had the format on save enabled so many of the modified files got auto-formatted and didnt catch it when seeing the changes. |
Updated all print statements to use debugPrint for improved logging practices in Flutter.
Changed the library declaration from 'apidash_core' to 'better_networking' to match the package name.
Replaces the import of better_networking with apidash_core in the test file to reflect the correct package dependency.
Renamed the internal _cleanup and _handleError functions to cleanup and handleError, respectively, and updated all references.
Included HTTPVerb.options in the kMethodsWithBody constant to ensure OPTIONS requests are recognized as supporting a body.
PR Description
This PR aims to separate all the networking related contents from apidash_core and instead re-package them into another public flutter package named better_networking.
This package contains all of the networking parts that apidash relies on. Including httpRequest creation, cancellation, HttpRequest & HttpResponse Models and so on
Moreover as a new feature, HTTP Streaming has been implemented with cancellation ability. This allows future expansion of apidash into Server Side Events (SSE), WebSockets and Streaming GenAI Responses
Streaming Request Example
Cancelling Stream Request
Checklist
main
branch before making this PRflutter upgrade
and verify)flutter test
) and all tests are passingAdded/updated tests?
We encourage you to add relevant test cases.
OS on which you have developed and tested the feature?