Create Lightning Apps and Aura Components
You can use Salesforce CLI to create Lightning apps and Aura components in your local Salesforce DX project. The generated files live in an aura directory in a package directory of your project.
-
Open a terminal (macOS and Linux) or command prompt Windows and change to your Salesforce DX project directory.
-
Create the aura directory in the location you want to generate the Lightning app and Aura components. For example, if you want to generate them in the default package directory, create the
force-app/main/default/auradirectory if it doesn’t exist. -
Create a Lightning app or an Aura component; specify the app or component name with the
--nameflag and theauradirectory with the--output-dirflag.
Use the project deploy start command to deploy the new Lightning app and Aura component to your org.
See Also