Reputation: 163
I read a lot about JSHint configurator but missed one moment that would be helpful for me. For example when i write document.geetElementById
(there is an extra e) it says nothing. Is there any way to make JSHint to show errors like this? Thanks.
Upvotes: 0
Views: 50
Reputation: 4506
No, you cannot configure it like that, because it can't determine whether document has a geetElementById
method or not. (What if you tried adding one, that has almost the same name as a built-in function it should know about?)
On the other hand, if you mistyped document
(depending on your settings) you would get a warning, because jshint looks for a variable declaration by that name. document
, of course, is an exception, because you don't define it in your code, but it's globally available - jshint knows about this either because you set it using the globals
option, or you've specified a browser
environment.
Upvotes: 2