Kiran Joshi
Kiran Joshi

Reputation: 1876

Handle multiple html file in angular 4

I want to call differnet html file in Angular4.
In my project I have created directory abc. Directory structure is like :

 abc-->app  
       src
       Index.html
       abc.html
       *.css files
       *.js files
       *.json files
       *.ts files

I want to call abc.html page insted of index.html.
How can do this?

Is it possible in Angular 4?
If yes than how?
Please suggest me and if possible than provide an example of it.

Upvotes: 0

Views: 1096

Answers (1)

Prachi
Prachi

Reputation: 3574

In your angular-cli.json:

  "apps": [
    {
      "root": "src",
      "outDir": "dist",
      "assets": [
        "assets",
        "favicon.ico"
      ],
      "index": "abc.html", <----- Here you can specify the name
      "main": "main.ts",
      "polyfills": "polyfills.ts",
      "test": "test.ts",
      "tsconfig": "tsconfig.app.json",
      "testTsconfig": "tsconfig.spec.json",
      "prefix": "app",
      "styles": [
        "styles.css"
      ],
      "scripts": [],
      "environmentSource": "environments/environment.ts",
      "environments": {
        "dev": "environments/environment.ts",
        "prod": "environments/environment.prod.ts"
      }
    }
  ]

Upvotes: 2

Related Questions