ok() is not a function
See original GitHub issueHello!
Thank you for this great library!
I’m using a construct like this: expect(value).to.not.be.ok()
, however, I’m getting an error cause ok
is not a function.
When I use it like this: expect(value).to.not.be.ok
, it works fine, but raises an error in my IDE, cause this construct is not a call and is not assigned to anything, i.e. redundant construct.
I think it makes sense to make such constructs at least look like a normal function call like in my firxt example: expect(value).to.not.be.ok()
.
What do you think? Thanks!
Issue Analytics
- State:
- Created 7 years ago
- Comments:8 (7 by maintainers)
Top Results From Across the Web
TypeError: "x" is not a function - JavaScript - MDN Web Docs
The JavaScript exception "is not a function" occurs when there was an attempt to call a value from a function, but the value...
Read more >How to Handle JavaScript Uncaught TypeError: “x” is Not a ...
The Javascript TypeError: "x" is not a function occurs when calling a function on a value or object, which is not actually a...
Read more >Uncaught (in promise) TypeError: response.json is not a function
One use case of doing so would be when you are making a HTTP request using the fetch API, whereby you will have...
Read more >JavaScript error: Response.json is not a function | Bugfixes
Follow Me Online Here: My website/blog - https://peterelbaum.com✉️ My newsletter (weekly on Sundays) ...
Read more >TypeError: response.json is not a function in JavaScript
The "response.json is not a function" error occurs when we call the json() method on an object that is not the Response object...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Just to clarify the matter: we still get lots of requests regarding this. I think eventually, when we tackle some of the things on the Roadmap - we’ll have the flexibility of offering interfaces which don’t use properties. But I think it’d be very turbulent to change things right now. For now, linters & IDEs can be tweaked, or you can use
dirty-chai
- as @meeber mentioned.I’ll close this because of all of the above discussion, which is to say “we’re not saying wontfix, just wontfix-right-now”.
I think it’s worth looking into again. Just to make sure we don’t duplicate past efforts, here is a quote from @keithamus in the #371 thread that contains a ton of background information related to the original fix to this issue and the reason it got reverted: