mirror of
https://github.com/airbnb/javascript.git
synced 2026-01-14 15:37:55 -05:00
Edit sample code in 24.1 to follow rule 8.1
Replaced function expression with arrow function notation.
This commit is contained in:
@@ -2099,7 +2099,7 @@ Other Style Guides
|
||||
|
||||
...
|
||||
|
||||
$(this).on('listingUpdated', function (e, listingId) {
|
||||
$(this).on('listingUpdated', (e, listingId) => {
|
||||
// do something with listingId
|
||||
});
|
||||
```
|
||||
@@ -2112,7 +2112,7 @@ Other Style Guides
|
||||
|
||||
...
|
||||
|
||||
$(this).on('listingUpdated', function (e, data) {
|
||||
$(this).on('listingUpdated', (e, data) => {
|
||||
// do something with data.listingId
|
||||
});
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user