Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: replace functions with arrow functions #6203

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion doc/api/errors.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -410,7 +410,7 @@ allowable type. For example, passing a function to a parameter which expects a
string would be considered a TypeError.

```js
require('url').parse(function() { });
require('url').parse(() => { });
// throws TypeError, since it expected a string
```

Expand Down
2 changes: 1 addition & 1 deletion doc/api/vm.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ context. The primary use case is to get access to the V8 debug object:

```js
const Debug = vm.runInDebugContext('Debug');
Debug.scripts().forEach(function(script) { console.log(script.name); });
Debug.scripts().forEach((script) => { console.log(script.name); });
```

Note that the debug context and object are intrinsically tied to V8's debugger
Expand Down