Version 1

    Eclipse VJET is a new 3rd-party tool that is available for installation from Central. Well integrated into Eclipse WTP, VJET aims to replace standard JSDT (JavaScript Development Tools) in Eclipse. VJET provides its own JavaScript Editor ('VJET Editor') with Content Assistant facility that allows you create/edit JavaScript files (*.js) as well as to edit JavaScripts on HTML pages. It also provides a number of views and outlines that help to browse the existing JavaScript structure, Type Space, Types, Members and so on.

    Installing Eclipse VJET into JBoss Developer Studio


    Due to simplify the Eclipse VJET installation and to allow our users to have it handy we've included the Eclipse VJET to 3rd-party products available for installation from JBoss Central. To install Eclipse VJET you need to perform the following few simple steps:


    • Open JBoss Central and select 'Software/Update' tab and type 'vjet' in filter field. You'll see the only 'Eclipse VJET' item in the list of 3rd-party software under 'Web and Mobile Development'. Select 'Eclipse VJET' and press 'Install' button below:


    • Make sure that at least 'Eclipse VJET JavaScript IDE (Incubation)' item is selected and press 'Next >' button:


    • Select at least one License in the list and make sure that 'I accept the terms...' radio is selected, then press 'Next >' button:


    • Wait a bit while installation process is finished...


    • ... then restart JBoss Developer Studio


    Most part of installation is finished so you can try to use Eclipse VJET's features.


    Using Eclipse VJET


    We've used HTML 5 Example project imported from JBoss Central hereafter:




    But you can create a new project from scratch or use an existing project. Eclipse VJET requires to be enabled on a project you're developing and suggests you to make it automatically when you're opening a JavaScript file for the first time:




    Press 'Enable' button to enable Eclipse VJET on your project.


    Most usefull feature of VJET is Content Assistant. For a number of reasons, VJET requires a file to be saved due to provide a Content Assist. So, we've made a new line and saved the document:




    ...and invoked Content Assistant by pressing Ctrl-Space:




    ...and then applied the selected property on the document:




    Using Eclipse VJET's Type Libraries


    JavaScript is a scripting language that is not precompiled, so the Object Types are poorly calculated. But there are number of well known libraries that are supported by Eclipse VJET in form of Type Library Projects that could be imported into your workspace due to provide types and method signatures for the Content Assist and Validation.


    If you want such information to be available for your project:


    • Clone the Type Libraries Project from Eclipse's Git repository 'git://' into a local folder:


    • Then return to your Workspace, select 'File->Import->Existing Projects into Workspace' and press 'Next >'


    • Find and select 'org.eclipse.vjet.typelibs' folder and press 'OK'


    • Then select the Type Library project(s) you want to add to your project and press 'Finish' - the required Type Library Project(s) will be imported into your Workspace


    • Right-click on your project and select 'Properties->VJET->VJET Build Path', then select 'Projects' Tab and press 'Add' button. Then select imported Type Library Project(s) and press 'OK' button:


    • Now you can use the information provided by selected Type Library in Content Assistant for your project, so you're able to select...


    • ... and apply these proposals:



    Without having the Type Library project imported and set up, the Content Assistant would be incomplete in most cases. For example, see the proposals of Content Assist invoked at the same file and position but with no jQuery Type Library project imported and referenced:




    Eclipse VJET Views to browse the project information


    Eclipse VJET provides a number of views that may help you to view a project details:




    AST View and Type Space View - AST Trees of original and recovered JavaScript and information on Types used in JavaScript:




    Outline, Types and Members Views: