Skip to content

ref(http): split http module to solve circular refs#11141

Merged
NathanWalker merged 6 commits intoNativeScript:mainfrom
CatchABus:ref/http-image
Mar 18, 2026
Merged

ref(http): split http module to solve circular refs#11141
NathanWalker merged 6 commits intoNativeScript:mainfrom
CatchABus:ref/http-image

Conversation

@CatchABus
Copy link
Contributor

@CatchABus CatchABus commented Mar 18, 2026

PR Checklist

What is the current behavior?

Right now, the http module is used for any purpose inside core and at the same time imports other modules from the same scope (e.g. ImageSource).
The same module is both for internal and public usage.

What is the new behavior?

Separate http response content functionality and create the http-request-internal module for internal use.
This ensures we expose the same http api for users while having a minimal http client to use internally.

Separating those comes with benefits:

  • Added missing types
  • Duplicate functions cleanup
  • Removed a wrong promise reject call from toFile that attempted to reject the fulfilled promise of the request itself

@nx-cloud
Copy link

nx-cloud bot commented Mar 18, 2026

View your CI Pipeline Execution ↗ for commit 6596627

Command Status Duration Result
nx test apps-automated -c=ios ✅ Succeeded 2m 10s View ↗
nx run-many --target=test --configuration=ci --... ✅ Succeeded 1s View ↗

☁️ Nx Cloud last updated this comment at 2026-03-18 17:56:07 UTC

@CatchABus CatchABus marked this pull request as ready for review March 18, 2026 17:48
@CatchABus CatchABus requested a review from NathanWalker March 18, 2026 17:48
Copy link
Contributor

@NathanWalker NathanWalker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Much better 💯

@NathanWalker NathanWalker merged commit fdf32d0 into NativeScript:main Mar 18, 2026
4 of 5 checks passed
CatchABus added a commit to CatchABus/NativeScript that referenced this pull request Mar 19, 2026
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