Skip to content

Commit 9ce9594

Browse files
committed
Remove outdated style guidance in contributors file
1 parent 0fad255 commit 9ce9594

File tree

3 files changed

+2
-34
lines changed

3 files changed

+2
-34
lines changed

CONTRIBUTING.md

Lines changed: 2 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -73,39 +73,9 @@ We rebase feature branches onto master when merging in order to maintain a linea
7373

7474
## Code Syntax & Style
7575

76-
We use [JSCS](https://www.npmjs.org/package/jscs) to enforce a basic set of code style guidelines, and [JSHint](http://jshint.com/) to guard against syntax errors. To run them both execute `npm run lint`; they will also be run every time you execute `npm test`.
76+
We use [ESLint](https://eslint.org/) to enforce a basic set of code style guidelines and syntax warnings. To run ESLint use the command `npm run lint`; this command will also be run every time you execute `npm test`.
7777

78-
JSCS is a useful tool for enforcing a code style, but isn't flexible enough to cover all guidelines. Note our standard for spacing within function parentheses, which is not enforced mechanically but will be evaluated manually when reviewing pull requests:
79-
80-
```javascript
81-
// Function params and args should be spaced out from the parentheses:
82-
someMethodCall( param1, param2 );
83-
function newFunction( arg1, arg2 ) {};
84-
```
85-
86-
"When in doubt, space it out," with the following exceptions.
87-
88-
```javascript
89-
// The space can be omitted when passing function expressions, object literals
90-
// or array literals as arguments:
91-
someMethodCall(function() {
92-
// do stuff
93-
});
94-
someOtherMethod({
95-
object: 'no space before an object literal'
96-
}, 'but this String argument still has a space after it' );
97-
someMethodThatTakesAnArray([
98-
'no',
99-
'leading or trailing',
100-
'spaces needed'
101-
]);
102-
```
103-
104-
We prefer `camelCase` variable and function names, and `UpperCamelCase` constructors. When using the `underscore_case` parameter names that are required by the WordPress API, the following JSHint directive can be used to disable the case enforcement for that particular file:
105-
106-
```javascript
107-
/*jshint -W106 */// Disable underscore_case warnings in this file
108-
```
78+
We prefer `camelCase` variable and function names, and `UpperCamelCase` constructors. `underscore_case` parameter names may be necessary when working with values returned from or intended to be sent to the WordPress REST API.
10979

11080
## Documentation
11181

lib/mixins/parameters.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
* @module mixins/parameters
88
*/
99
'use strict';
10-
/*jshint -W106 */// Disable underscore_case warnings in this file b/c WP uses them
1110

1211
const paramSetter = require( '../util/parameter-setter' );
1312
const argumentIsNumeric = require( '../util/argument-is-numeric' );

tests/integration/comments.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
/*jshint -W106 */// Disable underscore_case warnings in this file b/c WP uses them
21
'use strict';
32

43
const WPAPI = require( '../../' );

0 commit comments

Comments
 (0)