browser caching static files in flask?
caching, flask, openshift, python
Solution
Either use 'SEND_FILE_MAX_AGE_DEFAULT' or look into webassests http://webassets.readthedocs.org/en/latest/
Similar question asked here. Flask static file Cache-Control
Problem
Have been reading flask docs in python and building a local website. Just performed a speed test on my website deployed on openshift with this tool here:- The analysis report says that my site is not caching static resources. After googling this for all my worth I gather that:- - It has something to do with headers. - Cache copies are kept in the client machine and also servers between the client and website. My Question Am I to include expire and tags in the html section? Or in the HTTP header section? If in the HTTP header section how do I do this? If I have missed something in the docs please let me know.