404 Commits

Author SHA1 Message Date
Charles Lyding
bae9d06c7d fix(@angular/cli): sync webpack stats file content options 2017-08-03 18:05:15 +01:00
Filipe Silva
76779b15f8 fix(@angular/cli): update build-optimizer
Fix #7114
Fix #7110
Fix #7093
2017-08-03 10:03:21 -07:00
Filipe Silva
92902c6094 fix(@angular/cli): remove -bo alias for --build-optimizer
/cc @StephenFluin
2017-08-02 21:25:37 +01:00
JPeer264
260c781642 feat(@angular/cli): support includePaths for less (closes #7083) 2017-08-02 11:53:13 +01:00
Rakhat Jabagin
0007737579 docs: add other possible cases to generate in project readme 2017-08-02 09:29:13 +01:00
Charles Lyding
e486d17798 refactor(@angular/cli): update TS type dependencies 2017-08-01 09:09:15 +01:00
christian.scharr
70cf514a28 fix(@angular/cli): exclude node_modules while take account for os specific path separators (#6870) 2017-07-31 22:51:41 +01:00
Christian Scharr
b32064f5d5 fix(@angular/cli): use relative path instead of regex to exclude node_modules (#6870) 2017-07-31 22:51:41 +01:00
Filipe Silva
138f2b8cd3 fix(@angular/cli): show warnings on serve
Errors and warnings neet to be printed separately.

Followup to #6989
Fix #7213
2017-07-31 21:17:19 +01:00
Filipe Silva
5a84026a49 fix(@angular/cli): use 3 uglify passes with build-optimizer
PURE comments work best with 3 passes.
See https://github.com/webpack/webpack/issues/2899#issuecomment-317425926 for context and an example.

Thanks to @kzc for highlighting this.
2017-07-31 20:10:27 +01:00
cexbrayat
0e4b655254 fix(@angular/cli): change blog link to blog.angular.io 2017-07-31 14:43:30 +01:00
Aliaksei Kuncevic
abe39029a0 fix(@angular/cli): ignore yarn-error.log directory 2017-07-31 14:43:05 +01:00
Mike Brocchi
1c7e7bc66b fix(@angular/cli): Include missing dependency when ejecting 2017-07-31 14:40:27 +01:00
Charles Lyding
0888e82422 fix(@angular/cli): standardize output path behavior 2017-07-31 13:58:48 +01:00
AntoineC
06f3026042 fix(@angular/cli): add explicit source-map-support dependency (#7191)
karma plugin relies on source-map-support being a dependency of karma-source-map-support and npm 3+ flat dependency tree.

https://github.com/pnpm/pnpm/issues/863
2017-07-31 11:45:54 +01:00
Filipe Silva
7f6ab5c3f3 release: 1.3.0-rc.3 2017-07-27 12:30:05 -07:00
Filipe Silva
3baba67e50 Support enhanced resolve (#7169)
* fix(@ngtools/webpack): support enhanced-resolve@3.4.0

Followup to #7123

* fix(@angular/cli): unpin webpack 3.3.0

Followup to #7130
2017-07-27 08:53:04 -07:00
Filipe Silva
1ce3fe3f15 release: 1.3.0-rc.2 2017-07-26 14:28:50 -07:00
Juri Strumpflohner
0bb29fae8e fix(@angular/cli): change blog link to international one 2017-07-26 21:13:15 +01:00
Charles Lyding
a329014ddb fix(@angular/cli): prevent .cur file inlining
IE does not support data URI cursors.
2017-07-26 21:11:17 +01:00
Charles Lyding
bf55bfd044 fix(@angular/cli): remove deprecated json-loader 2017-07-26 21:10:57 +01:00
Filipe Silva
c26a5f774c fix(@angular/cli): pin webpack to 3.3.0
Webpack is updating to `enhanced-resolve@3.4.0` (16bf0b6f26) but the CLI cannot do so yet (see #7123).

This PR pins `webpack@3.3.0` until we are able to update to `enhanced-resolve@^3.4.0`.
2017-07-25 20:26:25 +01:00
Charles Lyding
2f68d53cc7 refactor: general dependency update 2017-07-22 12:53:03 +01:00
Hans Larsen
c4430bc894 release: v1.3.0-rc.0 2017-07-21 15:26:46 -07:00
Filipe Silva
7b9fc285e3 feat(@angular/cli): support TypeScript 2.4
This PR doesn't change new projects to use 2.4 since I have seen some reports of possible problems in `@angular/*`.

Instead, it:
- removes the dependency restrictions on <2.3
- bumps related dependencies to the minimum that supports 2.4 (`rxjs@^5.4.2`, `ts-node@~3.2.0`)
- builds the CLI itself using 2.4

So if you want to install ts 2.4 in your new project, the CLI itself won't stop you.

Fix #6827
2017-07-21 15:55:43 -04:00
Hans Larsen
61b4e2202f feat(@angular/cli): rewrite stats output to properly show the asset size
This is a feature in principle; the output is changed. The stats themselves dont though.
2017-07-21 14:42:55 -04:00
FrozenPandaz
6f23636323 feat(@angular/cli): add ability to build bundle for node and export lazy route map 2017-07-20 15:01:25 -07:00
Christian Liebel
d5d0b07812 feat(@angular/cli): update standard library to es2017
ECMAScript 2017 was released at the end of June. Standard library support for ES 2017 is around in TypeScript for quite a while now. Even `typescript@~2.0.0` which is used by the Angular 2 template supports a subset of ES 2017. Hence, it seems reasonable to update to the latest standard library version.
2017-07-19 16:04:16 -04:00
Michael Kühnel
35c89a5647 refactor: Change ejection message 2017-07-19 16:02:30 -04:00
Lukas Elmer
e970cb1c71 docs(@angular/cli): link to latest karma doc 2017-07-19 15:58:49 -04:00
jnizet
6ca6a5e92b fix(@angular/cli): fix doc command to work with new angular.io
- change the URL for the API search
- use google search when --search option is true, since angular.io doesn't have a search page anymore
- improve the help and doc of the doc command
2017-07-19 15:57:15 -04:00
Filipe Silva
826c634090 feat(@angular/cli): add flag to control chunk naming
Followup to #6881

Allow controlling chunk naming via the `--named-chunks` flag, which can be set on `.angular-cli.json` as well.

Defaults to true in development, false in production.
2017-07-19 13:53:07 -04:00
Filipe Silva
9ec5b4ed66 feat(@angular/cli): add build-optimizer support
Adds the new flag `--build-optimizer` (`--bo`), usable only with `--aot` (or `--prod` since it auto enables `--aot`).

This feature is experimental, and may not work correctly on your project. Should it work, total bundle size should go down. Savings are heavily dependent on the project.

See https://github.com/angular/devkit/tree/master/packages/angular_devkit/build_optimizer for details about all the optimizations applied.

Usage: `ng build --prod --build-optimizer`. Disabling the vendor chunk has been shown to improve total savings, and is done automatically when `--bo` is specified unless `--vendor-chunk` has a value.

Please let us know if using `--build-optimizer` breaks your project so we can improve it further. Repos are very welcome.
2017-07-19 12:27:23 -04:00
Yaroslav Admin
5c3146c49e build(@angular/cli): update webpack-dev-server to satisfy peer dependency 2017-07-19 11:14:01 -04:00
Filipe Silva
c027cc6aa2 build: unpin zone.js
Followup to #6971. `zone.js@0.8.14` has been released and we should unpin it.
2017-07-19 11:12:41 -04:00
Filipe Silva
ace2fe4e2f build: use webpack 3.3 2017-07-19 11:12:06 -04:00
Filipe Silva
5e8aadcb51 fix(@angular/cli): use build defaults in test
These defaults were added to build/serve/e2e but not to test.
2017-07-19 11:03:55 -04:00
Filipe Silva
455d56ed34 fix(@angular/cli): fix ng test report sourcemaps
#6160 broke `ng test` sourcemaps in Chrome, this PR fixes it.

Before:
```
kamik@T460p MINGW64 D:/sandbox/master-project (master)
$ ng test --sr
 10% building modules 1/1 modules 0 active13 07 2017 16:38:43.942:INFO [karma]: Karma v1.7.0 server started at http://0.0.0.0:9876/
13 07 2017 16:38:43.945:INFO [launcher]: Launching browser Chrome with unlimited concurrency
13 07 2017 16:38:43.953:INFO [launcher]: Starting browser Chrome                                                    13 07 2017 16:38:54.099:INFO [Chrome 59.0.
3071 (Windows 10 0.0.0)]: Connected on socket Xdep72ofT_Q7MWBHAAAA with id 76010950
Chrome 59.0.3071 (Windows 10 0.0.0) AppComponent should have as title 'app' FAILED
        Expected 'app' to equal 'forced bug'.
            at Object.<anonymous> (http://localhost:9876/_karma_webpack_/main.bundle.js:89:27)
            at ZoneDelegate.webpackJsonp.../../../../../../../sandbox/master-project/node_modules/zone.js/dist/zone.js.ZoneDelegate.invoke (http://localhost:9
876/_karma_webpack_/polyfills.bundle.js:2704:26)
            at AsyncTestZoneSpec.webpackJsonp.../../../../../../../sandbox/master-project/node_modules/zone.js/dist/async-test.js.AsyncTestZoneSpec.onInvoke (
http://localhost:9876/_karma_webpack_/vendor.bundle.js:55972:39)
            at ProxyZoneSpec.webpackJsonp.../../../../../../../sandbox/master-project/node_modules/zone.js/dist/proxy.js.ProxyZoneSpec.onInvoke (http://localh
ost:9876/_karma_webpack_/vendor.bundle.js:56735:39)
Chrome 59.0.3071 (Windows 10 0.0.0): Executed 2 of 3 (1 FAILED) (0 secs / 0.162 secs)
Chrome 59.0.3071 (Windows 10 0.0.0) AppComponent should have as title 'app' FAILED
        Expected 'app' to equal 'forced bug'.
            at Object.<anonymous> (http://localhost:9876/_karma_webpack_/main.bundle.js:89:27)
            at ZoneDelegate.webpackJsonp.../../../../../../../sandbox/master-project/node_modules/zone.js/dist/zone.js.ZoneDelegate.invoke (http://localhost:9
876/_karma_webpack_/polyfills.bundle.js:2704:26)
            at AsyncTestZoneSpec.webpackJsonp.../../../../../../../sandbox/master-project/node_modules/zone.js/dist/async-test.js.AsyncTestZoneSpec.onInvoke (
http://localhost:9876/_karma_webpack_/vendor.bundle.js:55972:39)
            at ProxyZoneSpec.webpackJsonp.../../../../../../../sandbox/master-project/node_modules/zone.js/dist/proxy.js.ProxyZoneSpec.onInvoke (http://localh
Chrome 59.0.3071 (Windows 10 0.0.0): Executed 3 of 3 (1 FAILED) (0.225 secs / 0.204 secs)
```

After:
```
kamik@T460p MINGW64 D:/sandbox/master-project (master)
$ ng test --sr
 10% building modules 1/1 modules 0 active13 07 2017 16:37:59.478:INFO [karma]: Karma v1.7.0 server started at http://0.0.0.0:9876/
13 07 2017 16:37:59.481:INFO [launcher]: Launching browser Chrome with unlimited concurrency
13 07 2017 16:37:59.487:INFO [launcher]: Starting browser Chrome                                                    13 07 2017 16:38:08.559:INFO [Chrome 59.0.
3071 (Windows 10 0.0.0)]: Connected on socket ixHN4NzVFTEW1iYiAAAA with id 92819713
Chrome 59.0.3071 (Windows 10 0.0.0) AppComponent should have as title 'app' FAILED
        Expected 'app' to equal 'forced bug'.
            at Object.<anonymous> D:/sandbox/master-project/src/app/app.component.spec.ts:23:23)
            at ZoneDelegate.webpackJsonp.../../../../../../../sandbox/master-project/node_modules/zone.js/dist/zone.js.ZoneDelegate.invoke D:/sandbox/master-p
roject/node_modules/zone.js/dist/zone.js:391:1)
            at AsyncTestZoneSpec.webpackJsonp.../../../../../../../sandbox/master-project/node_modules/zone.js/dist/async-test.js.AsyncTestZoneSpec.onInvoke D
:/sandbox/master-project/node_modules/zone.js/dist/async-test.js:49:1)
            at ProxyZoneSpec.webpackJsonp.../../../../../../../sandbox/master-project/node_modules/zone.js/dist/proxy.js.ProxyZoneSpec.onInvoke D:/sandbox/mas
ter-project/node_modules/zone.js/dist/proxy.js:76:1)
Chrome 59.0.3071 (Windows 10 0.0.0): Executed 2 of 3 (1 FAILED) (0 secs / 0.367 secs)
Chrome 59.0.3071 (Windows 10 0.0.0) AppComponent should have as title 'app' FAILED
        Expected 'app' to equal 'forced bug'.
            at Object.<anonymous> D:/sandbox/master-project/src/app/app.component.spec.ts:23:23)
            at ZoneDelegate.webpackJsonp.../../../../../../../sandbox/master-project/node_modules/zone.js/dist/zone.js.ZoneDelegate.invoke D:/sandbox/master-p
roject/node_modules/zone.js/dist/zone.js:391:1)
            at AsyncTestZoneSpec.webpackJsonp.../../../../../../../sandbox/master-project/node_modules/zone.js/dist/async-test.js.AsyncTestZoneSpec.onInvoke D
:/sandbox/master-project/node_modules/zone.js/dist/async-test.js:49:1)
            at ProxyZoneSpec.webpackJsonp.../../../../../../../sandbox/master-project/node_modules/zone.js/dist/proxy.js.ProxyZoneSpec.onInvoke D:/sandbox/mas
Chrome 59.0.3071 (Windows 10 0.0.0): Executed 3 of 3 (1 FAILED) (0.421 secs / 0.4 secs)
```

Fix #6583
2017-07-19 11:02:57 -04:00
Kevin Phelps
26e94339ba feat(@angular/cli): make the common chunk optional
- Add a "--no-common-chunk" build option for disabling the common async chunk.
- The existing behavior is maintained by default.

closes #7021
2017-07-19 10:13:24 -04:00
Filipe Silva
aebf4c89b1 fix(@angular/cli): wait for install to finish before exiting 2017-07-18 10:21:41 -04:00
Filipe Silva
19bbc7fb9d build(@angular/cli): use webpack@3.2 (#6949) 2017-07-14 15:36:25 -07:00
Mike Brocchi
f735760a34 fix(@angular/cli): Prevent re-reading config file if project & global are the same
Addresses #4207
2017-07-14 14:03:40 -07:00
Filipe Silva
6ad27c5174 fix(@angular/cli): always ignore node_modules for lint
Fix #6626
2017-07-14 14:02:45 -07:00
Filipe Silva
d4b64de427 build: pin zone.js
`zone.js@0.8.13` has some bugs that break our CI runs. These are being tracked in https://github.com/angular/zone.js/issues/832.

Until a these are fixed and a new versions is released, we should pin to `zone.js@0.8.12`. Another PR should go up then and unpin to `zone.js@^0.8.14`.
2017-07-13 16:25:52 -07:00
Hans Larsen
634a04190d
release: 1.3.0-beta.1 2017-07-12 11:44:46 -07:00
Filipe Silva
fe85750cb7 feat(@angular/cli): add scope hoisting via webpack 3
This should result in significant bundle size reduction. For best results, build for production with `--vendor-chunk=false`.

See https://medium.com/webpack/webpack-3-official-release-15fd2dd8f07b for details.
2017-07-10 16:59:08 -07:00
Filipe Silva
fd52246dfc feat(@angular/cli): allow chunk names for imports
Followup to #6881

Also name chunks created via `import()` or `System.import()`, and strip `.ngfactory` from the chunk name.
2017-07-10 10:33:57 -07:00
Filipe Silva
7f280499cd feat(@angular/cli): add build defaults to config
Adds following defaults to `.angular-cli.json` under `defaults`: `sourcemaps`, `baseHref`, `progress`, `poll`, `deleteOutputPath`, `preserveSymlinks`, `showCircularDependencies`.

They can be set via `ng set defaults.build.KEY = VALUE`.

Also removes `apps.0.showCircularDependencies`. This is not a breaking chance since it was only added in 1.3.0-beta.0.

Followup to https://github.com/angular/angular-cli/pull/6884#discussion_r125533830.
2017-07-06 15:03:19 -07:00
Filipe Silva
2780c3d7ab fix(@angular/cli): use inline sourcemaps in test
Fix #6737
2017-07-05 18:47:51 -07:00
Alexandr Marchenko
b0576d6d05 fix(@angular/cli): check package manager existance before installing packages 2017-07-05 16:47:47 -07:00