Setup Aptana Studio/Eclipse for ExtJS Development:
Aptana is powerful open source web development IDE. Please download and install Aptana Studio 3.
Now, you need to install Spket IDE plugin from spket.com. Spket is powerful toolkit for JavaScript and XML development. It enables autocomplete feature for ExtJS 4 once you install and configure Spket IDE plugin in Aptana or Eclipse.
Install Spket plugin in Aptana or Eclipse:
- Open Aptana/Eclipse.
- Go to Help menu -> 'Install New Software..'
- It will open following popup window as below:
- Click 'Add' and enter name 'Spket' and Location 'http://www.agpad.com/update/'.
- Click OK.
- Select all the packages under Spket IDE:
- Click 'Next'.
- Accept the License Agreement.
- Click 'Finish'.
- This will download and install Spket IDE plugin in Aptana/Eclipse.
- After installation -> restart Aptana/Eclipse.
Now, you need to configure Spket plugin. But before you do that, download JCB for ExtJS 4.2.1. Open http://www.agpad.com/downloads/ext-4.2.1.883.jsb2 in browser and save as ext-4.2.1.883.jsb2 in the root directory of ExtJS SDK/library.
Follow below steps to configure Spket plugin in Aptana/Eclipse in windows platform:
- Start Apatana or Eclipse.
- Go to Windows menu -> Preference.
- Expand Spket -> select Javascript Profiles.
- Click 'New..'
- Enter Name as ExtJS and click OK.
- Now, select ExtJS profiles and click 'Add Library'.
- Select ExtJS from drowdown and click 'OK'.
- Now, select ExtJS child node and click 'Add File'.
- Now, select jcb2 file from ExtJS library folders where you copied earlier.
- Now, set ExtJS profile as Default profile by clicking on Default button.
- Click OK and restart Aptana or Eclipse.
Now, create new project and JavaScript file and press Ctrl + Space, it will show you autocomplete with help like below:
So this way you can get autocomplete feature in Aptana or Eclipse.
JavaScript Syntax errors and warnings:
Aptana or Eclipse comes with JSLint and JavaScript Syntax validators. However, JSLint validator is disable by default. To enable it,
- Go to Windows -> preference.
- Expand Aptana Studio node.
- Select Validation. There you will see JSLint Validator:
- Select JSLint validator and click OK.
So now you will get JavaScript errors and warning of your project in Problems window. However, you need to exclude extjs sdk folder because JSLint shows errors and warning for many sdk JS files.
To exclude it, right click on sdk folder in project explorer -> select Properties -> select Resource Filter under Resource node and click 'Add':
Select Exclude All, Files and Folders, All Children and enter * as below:
So now, you only get errors and warning for your JavaScript files only.
Format JavaScript code:
Aptana comes with default code formatter for JavaScript. Press Ctrl + Shift + F to format JavaScript code in Aptana.
So this way you can setup development environment using Aptana or Eclipse IDE in Windows platform.
Original Source : extjs-tutorial.com/extjs/setup-aptana-for-extjs-development
0 comments:
Post a Comment
Silahkan isikan comment box untuk komentar Anda..