Turn on ESLint in examples directory, apply examples-specific exceptions

This commit is contained in:
Wojciech Maj 2018-12-06 13:54:38 +01:00
parent 9a1e51af24
commit 80d7ff4912
3 changed files with 33 additions and 1 deletions

View File

@ -2,7 +2,6 @@ build/
l10n/ l10n/
docs/ docs/
node_modules/ node_modules/
examples/
external/bcmaps/ external/bcmaps/
external/webL10n/ external/webL10n/
external/cmapscompress/ external/cmapscompress/

24
examples/.eslintrc Normal file
View File

@ -0,0 +1,24 @@
{
"extends": [
"../.eslintrc"
],
"parserOptions": {
"ecmaVersion": 5,
},
"env": {
"es6": false,
},
"globals": {
"pdfjsImageDecoders": false,
"pdfjsLib": false,
"pdfjsViewer": false,
"Uint8Array": false,
},
"rules": {
"object-shorthand": ["error", "never"]
}
}

9
examples/node/.eslintrc Normal file
View File

@ -0,0 +1,9 @@
{
"extends": [
"../.eslintrc"
],
"env": {
"node": true,
},
}