Open angelozerr opened 10 years ago
This could be tricky, since at the moment we are using goog.require
to define stand-in types for required names. If we were going to do validation, we would have to depend on a file finder, and flag an error if the name wasn't found.
I'm not sure that we will be able to identify classes that aren't provided reliably enough to provide helpful lint errors.
If we were going to do validation, we would have to depend on a file finder, and flag an error if the name wasn't found.
What is the problem with file finder? If you tell me that file finder is the solution, tern lint can manage that because you can define your own lint function.
The challenge is that a finder isn't always present, and also that finders operate asynchronously. We could probably make it work, though.
For your information, I have started tern lint https://github.com/angelozerr/tern.lint
You can validate too custom validation, like goog.require('classWichDoesn'tExists
I will happy to explain you how it works and we could discuss too how to improve it.