Changes between Initial Version and Version 1 of Ticket #21170, comment 102
- Timestamp:
- 12/07/2015 11:01:56 PM (9 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #21170, comment 102
initial v1 3 3 * The whole`MethodsAvailable` is weird readability wise. It works because the declaration of the variable is hoisted to the top, then the functions are hoisted and then `MethodsAvailable` is set to the correct value. I think it's better to be explicit that that's going on so to fix that add a `var MethodsAvailable` on top and moving the assignment to the bottom. 4 4 * If the first argument of `doAction` is required shouldn't it just be placed in the first position in the function declaration? Same goes for `applyFilters`. 5 * We can document that we accepta list of arguments using 3 dots: http://usejsdoc.org/tags-param.html, so for `doAction`: `@param {...}`5 * It is possible to document that a function accepts a list of arguments using 3 dots: http://usejsdoc.org/tags-param.html, so for `doAction`: `@param {...}` 6 6 * There is a space missing before the first `(` of all if statements. 7 7 * `_removeHook` doesn't need a context argument because it's never called with a context. This also makes the function cleaner.