File tree 3 files changed +4
-2
lines changed
3 files changed +4
-2
lines changed Original file line number Diff line number Diff line change 12
12
# add new ECMAScript features gradually
13
13
no-var : 2
14
14
prefer-const : 2
15
+ prefer-rest-params : 2
Original file line number Diff line number Diff line change @@ -119,9 +119,9 @@ not invoke AsyncHooks recursively because it is synchronous.
119
119
const fs = require (' fs' );
120
120
const util = require (' util' );
121
121
122
- function debug () {
122
+ function debug (... args ) {
123
123
// use a function like this one when debugging inside an AsyncHooks callback
124
- fs .writeSync (1 , util .format . apply ( null , arguments ) );
124
+ fs .writeSync (1 , ` ${ util .format ( ... args) } \n ` );
125
125
}
126
126
```
127
127
Original file line number Diff line number Diff line change @@ -55,6 +55,7 @@ added: v0.8.0
55
55
The ` util.deprecate() ` method wraps the given ` function ` or class in such a way that
56
56
it is marked as deprecated.
57
57
58
+ <!-- eslint-disable prefer-rest-params -->
58
59
``` js
59
60
const util = require (' util' );
60
61
You can’t perform that action at this time.
0 commit comments