| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
There was a problem hiding this comment.
There is already usage of {any} which seems to fit this situation better. Ditto below.
Sorry, something went wrong.
There was a problem hiding this comment.
The documentation doesn't mention how anything other than a RegExp or a Function (either a constructor or a validation function) would work. I.e., I don't think it can be an Error object, only an Error constructor. Ditto for .throws().
Sorry, something went wrong.
There was a problem hiding this comment.
Well, technically any value (not just booleans and numbers) would work. I'd be fine with either any or Boolean. since the concepts of truthy-ness and falsy-ness are defined by Boolean(val).
Sorry, something went wrong.
There was a problem hiding this comment.
Any type would work with this function. The examples below are just that -- examples.
Sorry, something went wrong.
|
Thanks for the review - changes made. |
Sorry, something went wrong.
There was a problem hiding this comment.
Nit: can you please remove these spurious/extra new lines?
Sorry, something went wrong.
There was a problem hiding this comment.
Done.
Sorry, something went wrong.
There was a problem hiding this comment.
I think this is actually any given the description below...
Sorry, something went wrong.
There was a problem hiding this comment.
Should be any, like assert.ok
Sorry, something went wrong.
|
Landed in 76e3e49 |
Sorry, something went wrong.
Refs: nodejs#9399 PR-URL: nodejs#11548 Reviewed-By: Timothy Gu <timothygu99@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Yuta Hiroto <hello@about-hiroppy.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
| Back | FazBrowse Home | New Git URL |
Checklist
Affected core subsystem(s)
documentation
Description of changes
Added argument data types to the docs for the assert module.
Issue