-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
EnJoiable Documentation for ".describe()" #441
Comments
How's this for a start? https://gist.github.com/myndzi/8ec496e429fd2f4ff783 |
👍 but actually I though of a joi document describing the output of describe |
I know you did, but I'm not that meta, and I find it dubiously useful :P |
I think that @myndzi approach is perfect for the documentation. Why is it not merged? |
Why is which not merged? I'm not seeing a related PR. |
@danielo515 I'd love to take a look at a PR if one lands for improving the functionality of |
@WesTyler it's not technically a PR, but there is an obvious piece of documentation that can be added by any member of the team. My question may be reformulated as: What's wrong about the proposed documentation ? |
@DavidTPate I can think on several ways of improving the describe method. However, most of them are biased and targeted at specific use cases. Ideally an improvement would be to allow developers extend the behavior of describe, like it's possible for new types and rules. |
Bump? Took me a while to get here and this functionality is required if this is to be used in a production level api. |
How so ? |
We need to be able to show how the API validates the input in the documentation. |
Are you using hapi? We have hapi-swagger enabled on our services to show the route validation rules, apart from |
Hapi-swagger makes an excellent job turning joi descriptions into examples, forms and api descriptions. It's awesome. I would love to see some of that features as a standalone plugin |
|
Ah, bummer. I still have a branch that is in progress for this. It's just gotten difficult to find time to prioritize it. :/ |
Thats understandable, but am I to understand that this is part of the stable API? That would be good enough for me. |
Until it is documented fully, it can technically be changed without notice. That being said, it has been stable for quite some time. There may be changes as documentation clears up inconsistencies and oddities, but I use it a LOT right now. |
Should I open a PR merging https://gist.github.com/myndzi/8ec496e429fd2f4ff783 into https://github.com/hapijs/joi/blob/v13.4.0/API.md#describeschema? Is that documentation still correct? |
I'm going to close this now we have a basic documentation for it, not that there's no more work to do on it. |
This thread has been automatically locked due to inactivity. Please open a new issue for related bugs or questions following the new issue template instructions. |
It would be nice to have documentation on the output of ".describe". Preferably written in joi?!
The text was updated successfully, but these errors were encountered: