Add webassets support for CSS
Change base template to add support for minified CSS files.
This commit is contained in:
parent
dac5b37565
commit
a784b48b81
1 changed files with 8 additions and 5 deletions
|
@ -3,13 +3,16 @@
|
|||
<head>
|
||||
<link href='//fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,700,400italic' rel='stylesheet' type='text/css'>
|
||||
{% if USE_LESS %}
|
||||
<link rel="stylesheet/less" type="text/css" href="{{ SITEURL }}/{{ THEME_STATIC_DIR }}/css/style.less">
|
||||
<script src="//cdnjs.cloudflare.com/ajax/libs/less.js/2.5.1/less.min.js" type="text/javascript"></script>
|
||||
{% assets filters="less,cssmin", output="css/main.css", "css/pygments.min.css", "css/font-awesome.min.css", "css/style.less" %}
|
||||
<link rel="stylesheet" type="text/css" href="{{ SITEURL }}/{{ ASSET_URL }}">
|
||||
<script src="//cdnjs.cloudflare.com/ajax/libs/less.js/2.5.1/less.min.js" type="text/javascript"></script>
|
||||
{% endassets %}
|
||||
{% else %}
|
||||
<link rel="stylesheet" type="text/css" href="{{ SITEURL }}/{{ THEME_STATIC_DIR }}/css/style.min.css">
|
||||
{% assets filters="cssmin", output="css/main.min.css", "css/pygments.min.css", "css/font-awesome.min.css", "css/style.min.css" %}
|
||||
<link rel="stylesheet" type="text/css" href="{{ SITEURL }}/{{ ASSET_URL }}">
|
||||
{% endassets %}
|
||||
{% endif %}
|
||||
<link rel="stylesheet" type="text/css" href="{{ SITEURL }}/{{ THEME_STATIC_DIR }}/css/pygments.min.css">
|
||||
<link rel="stylesheet" type="text/css" href="{{ SITEURL }}/{{ THEME_STATIC_DIR }}/css/font-awesome.min.css">
|
||||
|
||||
{% if CUSTOM_CSS %}
|
||||
<link href="{{ SITEURL }}/{{ CUSTOM_CSS }}" rel="stylesheet">
|
||||
{% endif %}
|
||||
|
|
Loading…
Reference in a new issue