ES5 → 7: Use enhanced object properties

http://es6-features.org/#PropertyShorthand

Instead of doing {"foo": foo, "bar": bar, ...}, we can just do
{foo, bar} now.

The function parameters of EventHandlers have all been renamed to
camelCase to make use of this, as the JS style conventions intend.
Other functions will follow in a later commit.
This commit is contained in:
miruka
2019-07-18 04:17:35 -04:00
parent 4920ff6212
commit ea02ce2316
13 changed files with 70 additions and 119 deletions

View File

@@ -22,13 +22,13 @@ Banner {
}
]
buttonCallbacks: {
"forget": button => {
buttonCallbacks: ({
forget: button => {
button.loading = true
py.callClientCoro(
chatPage.userId, "room_forget", [chatPage.roomId], () => {
button.loading = false
})
}
}
})
}