mirror of
https://github.com/LightAir/turbo-rss.git
synced 2026-02-04 03:56:19 +00:00
add eslint
This commit is contained in:
28
.eslintrc.json
Normal file
28
.eslintrc.json
Normal file
@@ -0,0 +1,28 @@
|
|||||||
|
{
|
||||||
|
"env": {
|
||||||
|
"es6": true,
|
||||||
|
"node": true
|
||||||
|
},
|
||||||
|
"extends": "eslint:recommended",
|
||||||
|
"parserOptions": {
|
||||||
|
"sourceType": "module"
|
||||||
|
},
|
||||||
|
"rules": {
|
||||||
|
"indent": [
|
||||||
|
"error",
|
||||||
|
4
|
||||||
|
],
|
||||||
|
"linebreak-style": [
|
||||||
|
"error",
|
||||||
|
"unix"
|
||||||
|
],
|
||||||
|
"quotes": [
|
||||||
|
"error",
|
||||||
|
"single"
|
||||||
|
],
|
||||||
|
"semi": [
|
||||||
|
"error",
|
||||||
|
"always"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -44,7 +44,7 @@ function generateXML(data) {
|
|||||||
|
|
||||||
item_values.push({'turbo:content': {_cdata: fullContent}});
|
item_values.push({'turbo:content': {_cdata: fullContent}});
|
||||||
|
|
||||||
if (typeof item.related !== "undefined") {
|
if (typeof item.related !== 'undefined') {
|
||||||
ifTruePush(item.related, item_values, {
|
ifTruePush(item.related, item_values, {
|
||||||
'yandex:related': item.related.map(
|
'yandex:related': item.related.map(
|
||||||
function (related) {
|
function (related) {
|
||||||
|
|||||||
@@ -56,6 +56,7 @@
|
|||||||
"xml": "1.0.1"
|
"xml": "1.0.1"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
"eslint": "^4.19.1",
|
||||||
"folderify": "^1.1.0",
|
"folderify": "^1.1.0",
|
||||||
"grunt": "^0.4.5",
|
"grunt": "^0.4.5",
|
||||||
"grunt-cli": "^0.1.13",
|
"grunt-cli": "^0.1.13",
|
||||||
|
|||||||
Reference in New Issue
Block a user