Authored by 李奇

代码检查配置文件添加

{
"presets": [
["env", {
"targets": {
"browsers": [">1%", "android >=4", "ios >=8"]
}
}]
]
}
... ...
root = true
[*]
indent_style = space
indent_size = 4
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
[*.md]
trim_trailing_whitespace = false
... ...
**/bundle/**/*.js
**/dist/**/*.js
coverage
public/static/js-sdk
public/static/yas-jssdk
public/js/home/jquery.upload.js
public/js/activity/live
... ...
{
"extends": "yoho",
"parserOptions": {
"sourceType": "module"
},
"plugins": [
"html"
],
"rules": {
"camelcase": "off"
}
}
\ No newline at end of file
... ...
**/css/**/*.css
**/dist/**/*.css
**/scss/activity/_aslider.css
**/scss/layout/_swiper.css
**/scss/activity/trend/_map.css
**/scss/activity/live/*.css
... ...
{
"extends": "stylelint-config-yoho",
"processors": ["stylelint-processor-html"],
"rules": {
"string-quotes": "double",
"no-empty-source": null
}
}
... ...
... ... @@ -3,7 +3,6 @@
* @author: leo
* @date: 23/06/2017
*/
const redis = require('redis');
const redisCli = global.yoho.utils.redisCli;
function getAll(req, res) {
... ... @@ -13,7 +12,7 @@ function getAll(req, res) {
data: {
total: +reply
}
})
});
});
}
... ...
... ... @@ -4,11 +4,12 @@
* @date: 23/06/2017
*/
const express = require('express');
const router = express.Router();
const router = express.Router(); // eslint-disable-line
const vote = require('./controllers/vote');
router.get('/', vote.getAll);
router.post('/', vote.addOne);
// router.get('/:vote_id', vote.getOne);
// router.put('/:vote_id', vote.putOne);
// router.delete('/:vote_id', vote.deleteOne);
... ...