-
Notifications
You must be signed in to change notification settings - Fork 135
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
🐛 API calls are not logged with withFetch() API in newer versions of Angular #2911
Comments
Hello @gokberknur, Thanks for reaching out. Indeed, in the example you provided, when forcing Angular to use To solve this issue we suggest to either:
|
Thank you for your reply. I think datadog rum is already initialized synchronously in our application, and it still doesn't work. However, we are not in favor in this solution anyway, considering size of the datadog-rum package is already big. Currently we removed the "WithFetch()" flag and using XHR. I hope datadog will support this in the near future. |
This is not something we can fix without a change in Angular. I submited an issue to see if they would be willing to support this use case. |
Thank you so much for your investigation! @BenoitZugmeyer |
It looks angular team released v18.2.3 that fixing this issue. I tried locally and i see API request now. |
if you configure an angular app with new "withFetch()" flag.
https://angular.dev/api/common/http/withFetch
api calls are not logged in datadogRUM.
we updated our application to angular v18 and started to use withFetch() flag in Angular's httpClient. We noticed that our API calls are not being logged anymore in datadog RUM.
To reproduce this issue you can try this sample-repo with fetch flag and without it in Angular HttpClient, then check the logs from RUM panel.
https://github.com/gokberknur/datadogRumNg18/blob/main/main.ts
The text was updated successfully, but these errors were encountered: