peter-murray / node-hue-api

Node.js Library for interacting with the Philips Hue Bridge and Lights
Apache License 2.0
1.18k stars 144 forks source link

Cannot be used in browser due to a minor issue #233

Open deadcyclo opened 9 months ago

deadcyclo commented 9 months ago

I've spent the evening trying to get this to work (only importing the api to not get issues with the discovery service) in a vue3 project using several polyfills to get the needed node functionality in the browser. Unfortunately it wasn't successful due to I minor issue. You have used the headers.raw() function, which is a node-fetch only feature, and not available in browsers. Would you please consider re-writing this to not use headers.raw() so it can be used in browsers?