Get basic grunt-ified CSS and JS working. Note that this currently uses the dist bundles for both prod and debug.
This commit is contained in:
parent
cbd0f30070
commit
7aab6a9fdd
13 changed files with 52 additions and 28831 deletions
|
@ -116,13 +116,25 @@ def random_string():
|
|||
return ''.join([random.choice(string.ascii_uppercase + string.digits) for _ in range(8)])
|
||||
|
||||
def render_page_template(name, **kwargs):
|
||||
library_styles = []
|
||||
main_styles = ['dist/quay-frontend.css']
|
||||
|
||||
library_scripts = []
|
||||
main_scripts = ['dist/quay-frontend.js']
|
||||
|
||||
cache_buster = random_string()
|
||||
|
||||
resp = make_response(render_template(name, route_data=json.dumps(get_route_data()),
|
||||
main_styles=main_styles,
|
||||
library_styles=library_styles,
|
||||
main_scripts=main_scripts,
|
||||
library_scripts=library_scripts,
|
||||
feature_set=json.dumps(features.get_features()),
|
||||
config_set=json.dumps(getFrontendVisibleConfig(app.config)),
|
||||
mixpanel_key=app.config.get('MIXPANEL_KEY', ''),
|
||||
is_debug=str(app.config.get('DEBUGGING', False)).lower(),
|
||||
show_chat=features.OLARK_CHAT,
|
||||
cache_buster=random_string(),
|
||||
cache_buster=cache_buster,
|
||||
**kwargs))
|
||||
|
||||
resp.headers['X-FRAME-OPTIONS'] = 'DENY'
|
||||
|
|
Reference in a new issue