Angular-cli: Takes too long to set up an app.

Created on 6 Mar 2018  路  9Comments  路  Source: angular/angular-cli

It's a pain to setup an angular app as it takes a very long time to set up. Also, the size is very large.

It would be good if the dev team minifies the size as well as reduce the setup time.

Versions

Angular 5.0.0
<!--
Output from: `ng --version`.
If nothing, output from: `node --version` and `npm --version`.
  Windows (7/8/10). Linux (incl. distribution). macOS (El Capitan? Sierra?)
-->

Repro steps

  • Step 1
  • Step 2
  • Step 3

Observed behavior

<!-- Normally this includes a stack trace and some more information. -->

Desired behavior

Mention any other details that might be useful (optional)

etmisc triage #1

All 9 comments

  1. npm install -g angular/cli
  2. ng new foo
  3. cd foo
  4. ng start

I dont think 4 steps could be considered "long setup"

It's not about 4 steps it's all the dependencies installation that takes time

how much time does it need on your local?

Google needs to do something on setup ang app takes too much time to install all dependencies

eg: ng new project alone takes almost 5-10 minutes wtf? don't ask about installing angular itself :(

Hope next release will be much better !! excuse my french

I want to add to this. Starting an angular project using the steps discussed above creates a 300MB directory. That's very large, especially for basic starter projects. Are there options to create lighter-weight projects?

Let's use this issue to reduce the total size of downloaded artifacts. I think this consumes the majority of the time on slow connections.

https://github.com/angular/angular-cli/pull/13821 cut the transitive download size of @angular/cli package in half, which is a great start for upcoming version 8.

Other things we can do next:

  • We can still make @angular/cli smaller. I think the next target should be @angular-devkit/core/node which could bundle in the chokidar library.
  • I have a little utility project http://github.com/alexeagle/syzer - I should be able to point it at a package.json produced by our default schematics and measure the total download size of a new project

I agree, generating a new app with angular 9 takes too long to install all the dependencies.
I'm surprised on how long the ng new app takes.

Is there somebody can explain why this duration ? it took more than 20 min (I'm using fiber, cpu i7, ...)

here my configuration :

Node : 12.16.0
npm: 6.13.4

Package Version

@angular-devkit/architect 0.900.1
@angular-devkit/core 9.0.1
@angular-devkit/schematics 9.0.1
@schematics/angular 9.0.1
@schematics/update 0.900.1

rxjs 6.5.3

@maniadel the solution is simple: don't use angular 馃槃 I only had this problem with angular

We're exploring ways to reduce the dependencies that Angular CLI has to download during project creation. The discussion doesn't seem very constructive at the moment, so I'll lock the issue. Expect updates in the changelog when we take an action.

Was this page helpful?
0 / 5 - 0 ratings