How to enable CORS in Python Dash

Solution
import dash
from flask_cors import CORS

app = dash.Dash(__name__)
server = app.server
CORS(server)

@app.route("/")
def helloWorld():
  return "Hello, cross-origin-world!"