Skip to content

Conversation

@sb-dor
Copy link

@sb-dor sb-dor commented Jun 22, 2025

This PR introduces a platform-aware http.Client factory to improve HTTP performance and behavior based on the underlying platform on issue #430 .

Changes made:
• Added createCustomClient() to return a specialized http.Client.
• Updated createDefaultHttpClient() to fallback to http.Client() if platform-specific creation fails.
• Conditional imports are used to keep the implementation cross-platform (including Web).

I’m still learning, and to be honest, I’m not very good at creating pull requests and I’m not even sure if the code is ideal. That’s why I’d really appreciate a discussion or any feedback on what’s good and what could be improved. Thank you very much.

@hawkkiller
Copy link
Owner

Thanks for the contribution!

@sb-dor sb-dor requested a review from hawkkiller June 25, 2025 00:21
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.

2 participants