Angular-cli: Multiple app defintions in the angular-cli.json "apps" : [ ] property

Created on 25 Jan 2017  Â·  6Comments  Â·  Source: angular/angular-cli

Multiple app definitions

I noticed that inside the angular-cli.json file, the "apps": property is defined as an array. Is the following a valid example of the intended use for this property?

angular-cli.json :

{
  "project": {
    "version": "1.0.0-beta.26",
    "name": "example1"
  },
  "apps": [
    {
      "root": "src",
      "outDir": "dist",
      ...
    }, 
    {
      "root": "src2",
      "outDir": "dist2",
      ...
    }
  ],
  ...
}

I've tested with multiple definitions in the "apps": property. And ng build always builds the first app defintiion.

If all these assumptions are correct, How do you use ng build to compile the second app definition?

Current Config.

angular-cli: 1.0.0-beta.26
node: 6.5.0
os: win32 x64
@angular/common: 2.4.4
@angular/compiler: 2.4.4
@angular/core: 2.4.4
@angular/forms: 2.4.4
@angular/http: 2.4.4
@angular/platform-browser: 2.4.4
@angular/platform-browser-dynamic: 2.4.4
@angular/router: 3.4.4
@angular/compiler-cli: 2.4.4

Most helpful comment

Is there a timeline for this? Could you suggest a workaround until then?

All 6 comments

That is the intended future use. However, only one app is currently supported.

Closing as answered by @clydin.

Is there a timeline for this? Could you suggest a workaround until then?

Thanks, that looks great Leo!

On Tue, Apr 4, 2017 at 10:01 AM, Leo Caseiro notifications@github.com
wrote:

Check https://github.com/sumitarora/angular-cli/blob/
8eacff23dee2ea9b9c29d9733dac3759133f5609/docs/documentation/
stories/multiple-apps.md

—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/angular/angular-cli/issues/4215#issuecomment-291342734,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ALPJvqL2zxyraXJ28Njlvay6K7tUgoFsks5rsY9VgaJpZM4LtEPu
.

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

_This action has been performed automatically by a bot._

Was this page helpful?
0 / 5 - 0 ratings

Related issues

delasteve picture delasteve  Â·  3Comments

rwillmer picture rwillmer  Â·  3Comments

jmurphzyo picture jmurphzyo  Â·  3Comments

IngvarKofoed picture IngvarKofoed  Â·  3Comments

hareeshav picture hareeshav  Â·  3Comments