Your server should handle the cors, not your frontend.