You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the discussion, corcoder raised an issue about CORS behavior when using FetchHttpClient in the Effect Typescript library, suspecting it might be a bug. sbrg suggested that the problem might be related to tracing, and identified that preflight requests include headers like b3, traceparent, which could trigger CORS restrictions. To work around this issue, sbrg provided a code snippet that disables tracing:
corcoder confirmed that this solution resolved their issue and expressed gratitude to sbrg. They also suggested that this information should be added to the documentation to help others who might face similar issues, especially newcomers to the Effect library.
sbrg agreed that an issue should be submitted and mentioned a bot—they referred to it as /issueify—that could potentially automate issue creation on the GitHub repository for Effect.
Key Takeaways:
CORS Issue with FetchHttpClient: The tracing mechanism can cause additional headers to be sent in HTTP requests, potentially causing CORS issues.
Tracing Workaround: Disabling tracing for HTTP requests is a viable workaround to prevent preflight requests from adding headers that trigger CORS restrictions.
Documentation Suggestion: There is a need to address this issue in the documentation to aid users, particularly newcomers.
Community Tools: The community has tools like the /issueify command to help streamline the process of creating GitHub issues from Discord discussions.
Summary
In the discussion, corcoder raised an issue about CORS behavior when using
FetchHttpClient
in the Effect Typescript library, suspecting it might be a bug. sbrg suggested that the problem might be related to tracing, and identified that preflight requests include headers likeb3, traceparent
, which could trigger CORS restrictions. To work around this issue, sbrg provided a code snippet that disables tracing:corcoder confirmed that this solution resolved their issue and expressed gratitude to sbrg. They also suggested that this information should be added to the documentation to help others who might face similar issues, especially newcomers to the Effect library.
sbrg agreed that an issue should be submitted and mentioned a bot—they referred to it as
/issueify
—that could potentially automate issue creation on the GitHub repository for Effect.Key Takeaways:
CORS Issue with FetchHttpClient: The tracing mechanism can cause additional headers to be sent in HTTP requests, potentially causing CORS issues.
Tracing Workaround: Disabling tracing for HTTP requests is a viable workaround to prevent preflight requests from adding headers that trigger CORS restrictions.
Documentation Suggestion: There is a need to address this issue in the documentation to aid users, particularly newcomers.
Community Tools: The community has tools like the
/issueify
command to help streamline the process of creating GitHub issues from Discord discussions.Discord thread
https://discord.com/channels/795981131316985866/1348263235148714096
The text was updated successfully, but these errors were encountered: