Closed aliaspooryorik closed 6 years ago
So you're talking about extending the existing taffy_docs_hide
implementation to also cover arguments for methods on otherwise visible resources? That sounds good to me.
FWIW, yes, we do (amazingly) still support CF8 but you can use continue thusly:
Also illustrated there is that we prefer the colon-delimited taffy:docs:hide
but also support taffy_docs_hide
for platforms/versions that don't support it with colons.
Lastly, could I ask you to do the same for the methods themselves (I could see someone wanting to support e.g. a PUT but have it be undocumented), and to add support for taffy:dashboard:hide
in all of the above locations as well?
I know there's a lot of little touches involved in all of that, and I appreciate your help!
So you're talking about extending the existing taffy_docs_hide implementation to also cover arguments for methods on otherwise visible resources?
Yes, that's the idea.
Was just hacking about with it locally and thought might as well chuck up as a discussion point, so glad you like the basic idea. Will have a look at your suggestions. They all sound sensible to me. 👍
@aliaspooryorik ping :)
@atuttle I have been pinged! Sorry for the delay :)
Think I've added support for the suggestions you raised previously
In the dashboard, check for
TAFFY_DOCS_HIDE
metadata on the resource argument. If it exists, do not include the argument in the constructed JSON or the dashboard docs sidebar.Was going to use
<cfcontinue>
instead of nesting in a<cfif>
but<cfcontinue>
is CF9+ and I believe Taffy supports CF8+.Reason for requested change.
I have arguments passed into my resource that are added in the
onTaffyRequest
method, so do not want them passed by the API caller. An example of this is to add aUser
argument parameter which is based on a header authentication token, so instead of looking it up in each resource, then I do it inonTaffyRequest
. Not sure if that is a valid use case but seems to work well.