-
Notifications
You must be signed in to change notification settings - Fork 286
feature(hooks): add decorators for declaring hooks #97
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
Conversation
Codecov Report
@@ Coverage Diff @@
## master #97 +/- ##
=========================================
+ Coverage 95.65% 96.3% +0.65%
=========================================
Files 66 99 +33
Lines 759 893 +134
Branches 106 114 +8
=========================================
+ Hits 726 860 +134
Misses 11 11
Partials 22 22
Continue to review full report at Codecov.
|
Great job. I've added one comment to your code :) |
export function AfterBulkCreate(options: IHookOptions): Function; | ||
export function AfterBulkCreate(...args: any[]): void|Function { | ||
|
||
if (args.length === 1) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would suggest to separate this (line 8-20) to an additional method in the hooks service cause these lines appear in every hook annotation. What do you think?
I messed up this branch. Re-opened the pull request as #101. |
Decorators for declaring hook methods in Model classes.
Includes README update, tests (100% coverage of new code).
Fixes #88