Making React App cross origin isolated with Flask back-end

100 Views Asked by At

I am currently using a library in which cross-origin isolation is required for my React app. I have very limited experience with CORS things and am struggling as to why this is not working.

I figured that sending the following headers with the after_request tag would do the trick:

def add_cors_headers(response):
    response.headers["Cross-Origin-Embedder-Policy"] = "require-corp"
    response.headers["Cross-Origin-Opener-Policy"] = "same-origin"
    return response 

However, when I go to test in my React app, using self.crossOriginIsolated, it tells me that I am not. What am I missing here?

0

There are 0 best solutions below