Closed laurentsenta closed 5 years ago
Thanks for maintaining this API and serving it btw! I'm so eager to use it I forgot the basics. Happy holidays!
Hey @lsenta! Sorry we didn't get to this sooner; I think the holidays caused us to miss it.
Responsibility-wise, this repository is only concerned with providing an express middleware; those server files you've modified are intended only to aid development of said middleware, and are not meant to be used in production (or by anyone that's not developing features on the middleware).
All that is to say that I don't think that these changes are necessary; if your server environment is throwing CORS errors, the intention is that you modify your own server's code to address them.
I hope that makes sense; please let me know if you have any further questions, or suggestions on how to prevent others from similar confusion in the future!
Closing this due to inactivity.
At the moment, loading the image on a canvas and trying to export it (toDataURL) throws a tainted canvas error.
The solution is to use a "crossOrigin=anonymous" on the canvas, which requires a CORS on the API.