Create an Oracle JET web app by using a starter template
Introduction
This tutorial shows you how to create an Oracle JavaScript Extension Toolkit (Oracle JET) web app that uses a navdrawer
starter template. You’ll use the npx
Node.js package runner to access the create
command provided by the Oracle JET command-line interface package.
Developing client-side web apps with Oracle JET is simple and efficient. To help you get started, Oracle JET provides starter templates. When you create your Oracle JET web app by using the navdrawer starter template, the template adds a preconfigured Oracle JET navigation drawer component to an initial web page.
You can create and run the Oracle JET web app from a terminal window by using the Oracle JET tooling package that is installed with the command-line interface. You can also see command output, such as app errors and warnings, in the terminal window.
Objectives
In this tutorial, you will create an Oracle JET web app that uses the navdrawer
template and run it in a local web browser.
Prerequisites
A development environment set up to create Oracle JET web apps that includes an installation of Node.js
Task 1: Get Started with the navdrawer Starter Template
-
In your file system, in the location where you want the Oracle JET web app to reside, open a terminal window and create the app.
npx @oracle/ojet-cli create JET_Web_Application --template=navdrawer --typescript
The Oracle JET tooling creates the app in the
JET_Web_Application
folder and displays progress messages until it finishes. -
Wait for confirmation.
Your app is ready! Change to your new app directory 'JET_Web_Application' and try 'ojet build' and 'ojet serve'.
Task 2: Run the Web App
-
In the terminal window, change to the
JET_Web_Application
directory and run the app.npx ojet serve
The Oracle JET tooling runs your web app in a local web browser where you can perform testing and debugging.
-
Close the browser window.
-
In the terminal window, press Ctrl+C, and, if prompted, enter
y
to exit the Oracle JET tooling batch job.
Next Step
To proceed to the next tutorial in this learning path, click here.
More Learning Resources
Explore other labs on docs.oracle.com/learn or access more free learning content on the Oracle Learning YouTube channel. Additionally, visit education.oracle.com/learning-explorer to become an Oracle Learning Explorer.
For product documentation, visit Oracle Help Center.
Create an Oracle JET web app by using a starter template
E97506-09
February 2024
Copyright © 2022, 2024, Oracle and/or its affiliates.