tom-sherman / immurl

🔗 A tiny immutable URL library, backed by the native whatwg URL.
https://immurl.netlify.app/
MIT License
31 stars 3 forks source link

Make isomorphic, support Node.js #9

Open tom-sherman opened 3 years ago

tom-sherman commented 3 years ago

For some reason this is not plug and play, likely due to inconsistencies between node-fetch and global fetch included in typescript.

Also, Headers are not available globally so passing anything other than an instances of Headers to the constructor of ImmutableHeaders throws an error as the internal Headers object cannot be created.

tom-sherman commented 1 year ago

This may be fixed in Node 18 where Headers et al are available globally.