-
Notifications
You must be signed in to change notification settings - Fork 27.4k
docs(jsdoc): remove @kind function
for providers
#8809
Conversation
@@ -252,7 +252,6 @@ function qFactory(nextTick, exceptionHandler) { | |||
/** | |||
* @ngdoc method | |||
* @name ng.$q#defer | |||
* @kind function |
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.
no, this was added just the other day, adding @ngdoc method
was not enough to get this to render correctly. revert
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.
It renders the same HTML for me with and without it. What exactly changes in the docs when you add/remove it? I can't find.
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.
It was a 2 step process to fix it --- adding @ngdoc method
was not enough, adding @kind function
fixed it.
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 don't think this is a CL worth landing, there's nothing really of value here, it doesn't correct anything weird
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.
Pretty much just revert everything that literally isn't a function (like $compileProvider) --- anything with a Provider
suffix can stay, but all of these methods, leave them as is
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.
OK, will do. But it looks like people just blindly copy-paste this tag, and it spreads epidemically throughout the code base without any value.
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.
Normally we aren't adding new providers, we're adding new methods --- so it makes sense to blindly copy the @function
tag. It's not clear why it was ever applied to Providers though.
@kind function
from everything but services@kind function
for providers
@caitp I've done what you requested ("Pretty much just revert everything that literally isn't a function (like $compileProvider) --- anything with a Provider suffix can stay, but all of these methods, leave them as is"). |
Taking a look~ |
LGTM |
As @petebacondarwin wrote in #7425,
@kind function
"is only relevant where we want to be able to tell the difference between a service that is an object and a service that is also callable". Also its presence leads to generation of strange 'Usage' sections in the docs for providers.