Skip to content
This repository was archived by the owner on Sep 5, 2024. It is now read-only.

Commit aa172b7

Browse files
Splaktarandrewseguin
authored andcommitted
style(eslint): enable array-bracket-spacing rule (#11587)
1 parent c68e7f0 commit aa172b7

File tree

21 files changed

+42
-42
lines changed

21 files changed

+42
-42
lines changed

.eslintrc.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"rules": {
77
"accessor-pairs": "error",
88
"array-bracket-newline": "off",
9-
"array-bracket-spacing": "off",
9+
"array-bracket-spacing": ["error", "never"],
1010
"array-callback-return": "error",
1111
"array-element-newline": "off",
1212
"arrow-body-style": "error",

config/ngModuleData.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ function buildScanner(pattern) {
3636
return match ? {
3737
name : moduleName || '',
3838
module : moduleName || '',
39-
dependencies : dependencies || [ ]
39+
dependencies : dependencies || []
4040
} : null;
4141
};
4242
}

docs/app/js/app.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
angular.module('docsApp', [ 'angularytics', 'ngRoute', 'ngMessages', 'ngMaterial' ], [
1+
angular.module('docsApp', ['angularytics', 'ngRoute', 'ngMessages', 'ngMaterial'], [
22
'SERVICES',
33
'COMPONENTS',
44
'DEMOS',
@@ -361,7 +361,7 @@ function(SERVICES, COMPONENTS, DEMOS, PAGES, $location, $rootScope, $http, $wind
361361
response = response.data;
362362
var versionId = getVersionIdFromPath();
363363
var head = { type: 'version', url: '/HEAD', id: 'head', name: 'HEAD (master)', github: '' };
364-
var commonVersions = versionId === 'head' ? [] : [ head ];
364+
var commonVersions = versionId === 'head' ? [] : [head];
365365
var knownVersions = getAllVersions();
366366
var listVersions = knownVersions.filter(removeCurrentVersion);
367367
var currentVersion = getCurrentVersion() || {name: 'local'};
@@ -370,11 +370,11 @@ function(SERVICES, COMPONENTS, DEMOS, PAGES, $location, $rootScope, $http, $wind
370370
name: 'Documentation Version',
371371
type: 'heading',
372372
className: 'version-picker',
373-
children: [ {
373+
children: [{
374374
name: currentVersion.name,
375375
type: 'toggle',
376376
pages: commonVersions.concat(listVersions)
377-
} ]
377+
}]
378378
});
379379
function removeCurrentVersion (version) {
380380
switch (versionId) {

docs/config/processors/buildConfig.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ module.exports = function buildConfigProcessor() {
1717
buildConfig: buildConfig
1818
});
1919

20-
return q.all([ getSHA(), getCommitDate() ])
21-
.then(function(){
20+
return q.all([getSHA(), getCommitDate()])
21+
.then(function() {
2222
return docs;
2323
});
2424
}

gulp/tasks/build-all-modules.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ const util = require('../util');
88

99
exports.task = function() {
1010
const isRelease = process.argv.indexOf('--release') !== -1;
11-
return gulp.src(['src/core/', 'src/components/*' ])
11+
return gulp.src(['src/core/', 'src/components/*'])
1212
.pipe(through2.obj(function(folder, enc, next) {
1313
const moduleId = folder.path.indexOf('components') > -1
1414
? 'material.components.' + path.basename(folder.path)

gulp/tasks/ddescribe-iit.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ function checkFile(fileContents, disallowed) {
4141

4242
exports.task = function() {
4343
let failures = void 0;
44-
return gulp.src(['src/**/*.spec.js', 'test/**/*-spec.js' ])
44+
return gulp.src(['src/**/*.spec.js', 'test/**/*-spec.js'])
4545
.pipe(through2.obj(function(file, enc, next) {
4646
const errors = checkFile(file.contents.toString(), kDisallowedFunctions);
4747
if (errors) {

release.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
const child_process = require('child_process');
1111
const pkg = require('./package.json');
1212
let oldVersion = pkg.version;
13-
const abortCmds = [ 'git reset --hard', 'git checkout staging', 'rm abort push' ];
14-
const pushCmds = [ 'rm abort push' ];
13+
const abortCmds = ['git reset --hard', 'git checkout staging', 'rm abort push'];
14+
const pushCmds = ['rm abort push'];
1515
const cleanupCmds = [];
1616
const defaultOptions = { encoding: 'utf-8' };
1717
const origin = '[email protected]:angular/material.git';
@@ -134,8 +134,8 @@
134134

135135
function getVersionOptions (version) {
136136
return version.match(/-rc\.?\d+$/)
137-
? [ increment(version, 'rc'), increment(version, 'minor') ]
138-
: [ increment(version, 'patch'), addRC(increment(version, 'minor')) ];
137+
? [increment(version, 'rc'), increment(version, 'minor')]
138+
: [increment(version, 'patch'), addRC(increment(version, 'minor'))];
139139

140140
function increment (versionString, type) {
141141
const version = parseVersion(versionString);
@@ -282,7 +282,7 @@
282282

283283
// update firebase.json file
284284
updateFirebaseJson();
285-
exec([ 'git commit --amend --no-edit -a' ], options);
285+
exec(['git commit --amend --no-edit -a'], options);
286286
done();
287287

288288
// add steps to push script

src/components/button/button.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
* Button
77
*/
88
angular
9-
.module('material.components.button', [ 'material.core' ])
9+
.module('material.components.button', ['material.core'])
1010
.directive('mdButton', MdButtonDirective)
1111
.directive('a', MdAnchorDirective);
1212

src/components/gridList/demoDynamicTiles/script.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ angular
1010
});
1111

1212
function buildGridModel(tileTmpl){
13-
var it, results = [ ];
13+
var it, results = [];
1414

1515
for (var j=0; j<11; j++) {
1616

src/components/menu/menu.spec.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -371,7 +371,7 @@ describe('material.components.menu', function() {
371371
' <md-button ng-click="doSomething($event)"></md-button>' +
372372
' </md-menu-item>' +
373373
' </md-menu-content>' +
374-
'</md-menu>', [ buttonAttrs || 'ng-click="$mdMenu.open($event)"' ]);
374+
'</md-menu>', [buttonAttrs || 'ng-click="$mdMenu.open($event)"']);
375375

376376
inject(function($compile, $rootScope) {
377377
$rootScope.doSomething = function($event) {

0 commit comments

Comments
 (0)