> For the complete documentation index, see [llms.txt](https://cedrus.gitbook.io/project-fusion/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://cedrus.gitbook.io/project-fusion/create-a-sample-demo.md).

# Create Sample Demo

This section explains how to use the business components easily from Cedrus Fusion Library in an application. The demo is presented by creating a sample application from scratch that uses/wires two business components from the library following the below steps:

1. Generate a new project using Angular Cli
2. Install Angular Material
3. Install Cedrus Fusion Library
4. Use the needed components and Wire them together.

## Generate a new Project <a href="#generate-a-new-project" id="generate-a-new-project"></a>

To create a new Angular 2 project, all what you to do is install angular-cli and then use it to create your project as following:

1. "npm install -g angular-cli" <--- Install Angular Cli
2. "ng new PROJECT\_NAME" <--- Create your project
3. "cd PROJECT\_NAME" <-Access your project directory

## Install Angular Material <a href="#install-angular-material" id="install-angular-material"></a>

To install angular material in your cli project, all what you have to do is:

1. "npm install --save @angular/material" <--- Install Angular Material
2. "npm install --save hammerjs" <--- Support library for Angular Material
3. \<link href="<https://fonts.googleapis.com/icon?family=Material+Icons>" rel="stylesheet"> <-- Include in**index.html**
4. Update app.module.ts by:

import { MaterialModule } from '@angular/material';

Add "MaterialModule.forRoot()" in the imports array of ngModule.

## Install Cedrus Fusion Library <a href="#install-cedrus-fusion-library" id="install-cedrus-fusion-library"></a>

1. "npm install --save cedrus-fusion" <---Install the library
2. Update app.module.ts by:

import { CfModule } from 'cedrus-fusion/src/app/app.module';

Add "CfModule" in the imports array of ngModule.+

## Use the needed components and Wire them together <a href="#use-the-needed-components-and-wire-them-together" id="use-the-needed-components-and-wire-them-together"></a>

Refer to the documentation of the components, create your customized objects to describe them and use the components in your templates.
