Flask file not updated on Javascript fetch Flask file not updated on Javascript fetch flask flask

Flask file not updated on Javascript fetch


If you want, you can force disabling cache for all your requests, something like:

@app.after_requestdef add_header(response):    response.cache_control.max_age = 300    if 'Cache-Control' not in response.headers:        response.headers['Cache-Control'] = 'no-store'    return response

or you can set the default value for all static files in your app:

app = Flask(__name___)app.config['SEND_FILE_MAX_AGE_DEFAULT'] = 60