Drift Angular
  • Overview
  • Package Content
  • Installation and Setup
    • Setup Environment
    • Setup Project
    • Setup Layout
    • Deployment
  • Structure
    • Folders and Files Structure
    • Layouts
    • Drift Icons
  • Stylesheets
    • Overview
    • Sass Variables
    • Layouts & Theme
    • Fonts
    • Colors
    • Back Ground Images
    • Margin & Paddings
    • Theme Customization
    • RTL Version
  • Settings
    • Template Setting
    • Customize Horizontal Menu
    • Customize Vertical Menu
    • Create a Page
    • Define Routes
    • Root Loader
    • RTL
    • Internationalization
  • Components
    • Alerts
    • Badges
    • Breadcrumbs
    • Buttons
    • Button Group
    • Cards
    • Card Group
    • Collapse
    • Dropdowns
    • Progress Bar
    • Tabs
Powered by GitBook
On this page

Was this helpful?

  1. Settings

Create a Page

Create New Page Component

PreviousCustomize Vertical MenuNextDefine Routes

Last updated 5 years ago

Was this helpful?

To add new page in your app, You have to create a new Page Component.

To create a Angular component run the following command in the command prompt on Windows PC or terminal on Mac.

$ ng generate component {component path}

// or you can use the shorter cammand given below

$ ng g c {component path}

Above cammand will create a component on given path. It will create four files.

For example we create a component 'home' then following files will be generated:

  1. home.component.html

  2. home.component.scss

  3. home.component.spec.ts

  4. home.component.ts

We can skip spec file add 3. home.component.spec.ts file using --skipTests=true

$ ng generate component --skipTests=true home

For more angular command here.

click