Skip to content

Commit

Permalink
chore: update eslintrc
Browse files Browse the repository at this point in the history
  • Loading branch information
kitian616 committed Feb 5, 2019
1 parent 9172e97 commit a16fd1f
Show file tree
Hide file tree
Showing 21 changed files with 25 additions and 23 deletions.
3 changes: 2 additions & 1 deletion .eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
"default-case": "error",
"no-extra-bind": "error",
"camelcase": "error",
"indent": ["error", 2, { "SwitchCase": 1 }]
"indent": ["error", 2, { "SwitchCase": 1 }],
"eol-last": ["error", "always"]
},
"extends": ["eslint:recommended"]
}
2 changes: 1 addition & 1 deletion _includes/pageview-providers/leancloud/leancloud.js
Original file line number Diff line number Diff line change
Expand Up @@ -68,4 +68,4 @@
}
}
window.pageview = pageview;
})();
})();
2 changes: 1 addition & 1 deletion _includes/scripts/article.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@
});
});
});
})();
})();
2 changes: 1 addition & 1 deletion _includes/scripts/aside/affix.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,4 @@

window.pageAsideAffix = affix;
});
})();
})();
2 changes: 1 addition & 1 deletion _includes/scripts/aside/toc.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,4 @@
}, 100));

});
})();
})();
2 changes: 1 addition & 1 deletion _includes/scripts/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@
$root.dataset.isTouch = true;
document.addEventListener('touchstart', function(){}, false);
}
})();
})();
2 changes: 1 addition & 1 deletion _includes/scripts/components/search.js
Original file line number Diff line number Diff line change
Expand Up @@ -83,4 +83,4 @@
});
}
});
})();
})();
3 changes: 1 addition & 2 deletions _includes/scripts/components/sidebar.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
window.Lazyload.js(SOURCES.jquery, function() {
var $pageMask = $('.js-page-mask');
var $pageRoot = $('.js-page-root');
var $pageMain = $('.js-page-main');
var $sidebarShow = $('.js-sidebar-show');
var $sidebarHide = $('.js-sidebar-hide');

Expand All @@ -28,4 +27,4 @@
stopBodyScrolling(false); $pageRoot.removeClass('show-sidebar');
});
});
})();
})();
2 changes: 1 addition & 1 deletion _includes/scripts/home.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/*(function () {
})();*/
})();*/
2 changes: 1 addition & 1 deletion _includes/scripts/lib/affix.js
Original file line number Diff line number Diff line change
Expand Up @@ -108,4 +108,4 @@
}
$.fn.affix = affix;
});
})();
})();
2 changes: 1 addition & 1 deletion _includes/scripts/lib/lazyload.js
Original file line number Diff line number Diff line change
Expand Up @@ -140,4 +140,4 @@
}
};
})(this.document);
})();
})();
2 changes: 1 addition & 1 deletion _includes/scripts/lib/modal.js
Original file line number Diff line number Diff line change
Expand Up @@ -61,4 +61,4 @@
}
$.fn.modal = modal;
});
})();
})();
2 changes: 1 addition & 1 deletion _includes/scripts/lib/scroll-to.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@
}
$.fn.scrollToAnchor = scrollToAnchor;
});
})();
})();
2 changes: 1 addition & 1 deletion _includes/scripts/lib/swiper.js
Original file line number Diff line number Diff line change
Expand Up @@ -200,4 +200,4 @@
}
$.fn.swiper = swiper;
});
})();
})();
2 changes: 1 addition & 1 deletion _includes/scripts/lib/throttle.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,4 @@
return result;
};
};
})();
})();
2 changes: 1 addition & 1 deletion _includes/scripts/lib/toc.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,4 +104,4 @@
}
$.fn.toc = toc;
});
})();
})();
2 changes: 1 addition & 1 deletion _includes/scripts/page.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/*(function () {
})();*/
})();*/
2 changes: 1 addition & 1 deletion _includes/scripts/utils/imagesLoad.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,4 @@
}
};
};
})();
})();
2 changes: 1 addition & 1 deletion _includes/scripts/utils/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,4 +40,4 @@
}
};
})();
})();
})();
2 changes: 1 addition & 1 deletion _includes/search-providers/default/search.js
Original file line number Diff line number Diff line change
Expand Up @@ -124,4 +124,4 @@ window.Lazyload.js([SOURCES.jquery, PAHTS.search_js], function() {
var itemIndex = $(this).parent().data('index');
itemIndex >= 0 && (lastActiveIndex = activeIndex, activeIndex = itemIndex, updateResultItems());
});
});
});
6 changes: 4 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,10 @@
"demo-dev": "bundle exec jekyll serve -H 0.0.0.0 -t --config ./docs/_config.yml",
"demo-beta": "JEKYLL_ENV=beta bundle exec jekyll serve -H 0.0.0.0 -t --config ./docs/_config.yml",
"demo-production": "JEKYLL_ENV=production bundle exec jekyll serve -H 0.0.0.0 -t --config ./docs/_config.yml",
"css-lint": "stylelint --syntax scss \"_sass/**/*.scss\"",
"css-fix": "stylelint --syntax scss \"_sass/**/*.scss\" --fix",
"eslint": "eslint \"_includes/**/*.js\"",
"eslint-fix": "eslint \"_includes/**/*.js\" --fix",
"stylelint": "stylelint --syntax scss \"_sass/**/*.scss\"",
"stylelint-fix": "stylelint --syntax scss \"_sass/**/*.scss\" --fix",
"gem-build": "rm -fv jekyll-text-theme-*.gem && gem build jekyll-text-theme.gemspec",
"gem-push": "gem push jekyll-text-theme-*.gem"
},
Expand Down

0 comments on commit a16fd1f

Please sign in to comment.