What is Oracle JET?
It supports the Model-View-ViewModel (MVVM) architecture to enable:
- The model to represent any application data
- The view for presentation of this data
- The ViewModel to control/manage the state of the application and expose the application data from the model to the view.
You can see more about the toolkit here and view the components available in the cookbook here.
There are a couple of pre-requisites of getting started with Oracle JET (note, these steps apply to Windows – there may be variation when using any other OS)
- Install Node.js here (always make sure you have the latest version!)
- To verify the installed version of node, you can use the following command:
- Use npm to install the Oracle JET command line interface (oject-cli) using the below command:
npm install -g @oracle/ojet-cli
It really is that simple to get moving with Oracle JET development. Now you have the pre-requisites as defined above, you can start developing using the following command (note to choose the app_name and template you wish):
ojet create <app name> --template=navdrawer|| navbar||basic||blank
Next, enter the app folder that you have just created using the following command (replacing <app name> with your chosen name):
cd <app name>
Use the following command to start up your application:
When you ojet serve your application, a listener is activated. If you change (and save!) code in your newly created application, the changes will automatically apply to your running app. the structure of your pre-generated code can be seen in the below image: