Skip to content

Proxy widget fetch through main process to bypass CORS#16

Merged
saeedvaziry merged 1 commit intomainfrom
fix/cors-fetch-proxy
Feb 26, 2026
Merged

Proxy widget fetch through main process to bypass CORS#16
saeedvaziry merged 1 commit intomainfrom
fix/cors-fetch-proxy

Conversation

@saeedvaziry
Copy link
Copy Markdown
Member

  • Override window.fetch in widget windows and preview iframe to route HTTP requests through Electron's main process via IPC
  • Add fetch:request IPC handler using net.fetch (no CORS restrictions) with graceful error handling for invalid URLs
  • Fix <script type="module"> tags not being preserved when widget HTML scripts are re-injected

Fixes #15

@saeedvaziry saeedvaziry merged commit 997597d into main Feb 26, 2026
@saeedvaziry saeedvaziry deleted the fix/cors-fetch-proxy branch February 26, 2026 22:36
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.

script type="module" for async functions

1 participant