I am using eclipse on my project and while messing around with my eclipse settings, I turned on Javascript support. Now eclipse complains that JQuery library has errors in it and is not letting me compile the project. Does anyone know how to turn javascript validation off?
Click Window > Preferences and select Validation in the left pane. The Validation page of the Preferences window lists the validators available in your project and their settings. To disable individual validators, clear the check boxes next to each validator that you want to disable.
The Validation Component in the wst sub project provides an extendable framework that is used to develop new custom validators to validate resources in the workbench. The resources can be an eclipse Resource (IResource) or an EMF Resource (EObject).
The JavaScript Development Tools (JSDT) provide plug-ins that implement an IDE supporting the development of JavaScript applications and JavaScript within web applications. It adds a JavaScript project type and perspective to the Eclipse Workbench as well as a number of views, editors, wizards, and builders.
I actually like MY JavaScript files to be validated, but I definitely don't want to validate and deal with trivial warnings with third party libraries.
That's why I think that turning off validation all together is too drastic. Fortunately with Eclipse, you can selectively remove some JavaScript sources from validation.
Excluded
pattern.Exclusion patterns
box.Browse
button to mention the JavaScript source by name.The information about JavaScript source inclusion/exclusion is saved into .settings/.jsdtscope
file. Do not forget to add it to your SCM.
Here is how configuration looks with jQuery files removed from validation:
Turn off the JavaScript Validator in the "Builders" config for your project:
Then either restart your Eclipse or/and rename the .js to something like .js_ then back again.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With