Skip to content

Commit 5c20f8d

Browse files
committed
ESLint, with the Google config
1 parent b2b385d commit 5c20f8d

File tree

56 files changed

+348
-375
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

56 files changed

+348
-375
lines changed

.eslintignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
_site/
2+
service-worker/serviceworker-cache-polyfill.js
3+
decorators-es7/

.eslintrc

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"extends": "google",
3+
"env": {
4+
"browser": true
5+
},
6+
"globals": {
7+
"ChromeSamples": true
8+
},
9+
"rules": {
10+
"require-jsdoc": 0,
11+
"no-inline-comments": 0
12+
}
13+
}

.jshintrc

Lines changed: 0 additions & 27 deletions
This file was deleted.

.travis.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@ language: ruby
22
rvm:
33
- 2.1
44
script:
5-
- bundle exec jekyll build
65
- npm install
7-
- gulp lint
6+
- npm run lint
7+
- bundle exec jekyll build
88
branches:
99
only:
1010
- /.*/

_config.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,4 @@ exclude:
1515
- README.md
1616
- node_modules
1717
- Gemfile
18-
- gulpfile.js
19-
- linter.rb
2018
- vendor

array-methods-es6/.eslintrc

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"rules": {
3+
"no-unused-vars": 0,
4+
"no-undef": 0,
5+
"space-infix-ops": 0
6+
}
7+
}

array-methods-es6/demo2.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
var divs = document.querySelectorAll("div");
1+
var divs = document.querySelectorAll('div');
22
Array.from(divs).forEach(function(node) {
33
console.log(node);
44
});

array-methods-es6/demo5.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
[0, 1, 2, 3, 4].copyWithin(target=0, start=3, end=4); // [3, 1, 2, 3, 4]
1+
[0, 1, 2, 3, 4].copyWithin(target=0, start=3, end=4); // [3, 1, 2, 3, 4]
22
[0, 1, 2, 3, 4].copyWithin(target=0, start=-2, end=-1); // [3, 1, 2, 3, 4]

array-methods-es6/demo7.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
function startsWithLetterA(element, index, array) {
2-
if (element.startsWith('a')) return element;
2+
if (element.startsWith('a')) {
3+
return element;
4+
}
35
}
46
var cuteNames = ['jeff', 'marc', 'addy', 'francois'];
57

array-methods-es6/demo8.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
function startsWithLetterA(element, index, array) {
2-
if (element.startsWith('a')) return element;
2+
if (element.startsWith('a')) {
3+
return element;
4+
}
35
}
46
var cuteNames = ['jeff', 'marc', 'addy', 'francois'];
57

0 commit comments

Comments
 (0)