Я запускаю фласк на
localhost:5000
и npm run start на
localhost:3000
у меня выпадает ошибка:
Access to fetch at 'localhost:5000/api/app' from origin 'localhost:3000' has been blocked by CORS policy: The 'Access-Control-Allow-Origin' header contains multiple values 'localhost:3000, localhost:3000', but only one is allowed. Have the server send the header with a valid value, or, if an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.
хедеры добавляю такие
response.headers.add('Access-Control-Allow-Origin', 'https://localhost:3000')
response.headers.add('Access-Control-Allow-Credentials', 'true')
response.headers.add('Access-Control-Allow-Headers', 'Content-Type,Authorization')
response.headers.add('Access-Control-Allow-Methods', 'GET,PUT,POST,DELETE,OPTIONS')
Как исправить?