logtail / logtail-js

Better Stack JavaScript client
https://betterstack.com/logs
ISC License
52 stars 12 forks source link

[Node]: [ReferenceError: XMLHttpRequest is not defined] #113

Open sannajammeh opened 3 months ago

sannajammeh commented 3 months ago

We're getting [ReferenceError: XMLHttpRequest is not defined] and no logs flushed when trying to use @logtail/node. Why is logtail attempting to use XMLHttpRequest?

We are running Next.js with Node 20

sannajammeh commented 3 months ago

You should bump cross-fetch to v4 which fixes this issue.

curusarn commented 3 months ago

Hey @sannajammeh,

Thanks a lot for raising this! I'm passing it on to the team. We'll get it fixed soon. We'll keep you updated here on GitHub.

Thank you for reaching out.