dev: hot reload only main css, (not fonts)

This commit is contained in:
jean-emmanuel 2016-12-07 21:09:34 +01:00
parent a83ff2b246
commit 07529b9753
2 changed files with 2 additions and 2 deletions

View file

@ -7,7 +7,7 @@
<link rel="preload" href="fonts/font-awesome.min.css"/>
<link rel="preload" href="fonts/droid-sans.css"/>
<link rel="preload" href="styles.css"/>
<link rel="stylesheet" href="styles.css"/>
<link rel="stylesheet" href="styles.css" hot-reload/>
<link rel="stylesheet" href="fonts/font-awesome.min.css"/>
<link rel="stylesheet" href="fonts/droid-sans.css"/>
<script src="scripts.js"></script>

View file

@ -117,7 +117,7 @@ var callbacks = module.exports = {
reloadCss: function(){
var queryString = '?reload=' + new Date().getTime();
$('link[rel="stylesheet"]').each(function () {
$('link[rel="stylesheet"][hot-reload]').each(function () {
this.href = this.href.replace(/\?.*|$/, queryString);
});
setTimeout(()=>{