2

I have experience using Netbeans with Java but am new to using it with Javascript. I know how to open javascript files within a Java Project but is there a way to open javascript in a "javascript project" where I might be able to "compile" the code and see possible errors. Is this possible or am I asking too much?

2 Answers 2

1

By compile, I'm assuming you mean simple validation (like using undefined variables or typos etc.)

I may be wrong, but netbeans has the worst javascript support. If you want simple validation of Javascript code, you may look at Eclipse javascript environment (or the Aptana plugin). IntelliJ IDEA has very decent validator as well.

Sign up to request clarification or add additional context in comments.

1 Comment

Thank you I will look into it and get back to you
0

To check for code quality you can use some JavaScript analysis tools like JSLint.

http://www.jslint.com/

But it's not nearly as good as compilation in a fully typed language like Java.

An alternative is to not write the JavaScript at all but use Java instead and have it converted to JavaScript. This gives you the advantage of writing fully typed code that can be statically analyzed and checked for errors. Google's GWT does this and there are other similar options.

http://www.artima.com/lejava/articles/java_to_javascript.html

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.