This PR adds tsconfigs for each separate application:
- `src/tsconfig.app.json`: configuration for the Angular app.
- `src/tsconfig.spec.json`: configuration for the unit tests. Defaults to the Angular app config.
- `e2e/tsconfig.e2e.json`: configuration for the e2e tests.
There is an additional root-level `tsconfig.json` that is used for editor integration.
For Angular version 4 projects, these tsconfigs will use inheritance since it's available with TypeScript 2.1.
This is not a breaking change. Existing projects should not be affected.
This provides implementations for the following serve command options:
live-reload [boolean; default: true] -- flag to control the browser live reload capability
live-reload-client [URL; default: ssl/host/port command options] -- specify the URL that the live reload browser client will use
Closes#3361
This is useful when you don't want the server to rebuild in the middle of something.
A good example is when running e2e tests. Especially on larger suites, one would prefer to continue working while the build is tested without compromising tests.
This will break tests on #4744. They should be adjusted to add the `--watch` flag since they depend on the live reload behaviour during `ng e2e`.
Heavily based on @jsanchezgarcia work in #4476.
Fix#3857
BREAKING CHANGE:
A new environmentSource entry replaces the previous source entry inside environments.
To migrate the code follow the example below:
Before:
```
"environments": {
"source": "environments/environment.ts",
"dev": "environments/environment.ts",
"prod": "environments/environment.prod.ts"
}
```
After:
```
"environmentSource": "environments/environment.ts",
"environments": {
"dev": "environments/environment.ts",
"prod": "environments/environment.prod.ts"
}
```
Allows you to run ng build --json which generates dist/stats.json. This can then be used with things like the webpack-bundle-analyzer or https://webpack.github.io/analyse/Fix#3179
BREAKING CHANGE: Removing the `ng init` & `ng update` commands because their current implementation causes more problems than it solves. Once RC is released, we won't need to use those to update anymore as the step will be as simple as installing the latest version of the CLI.
Uses existing Protractor API to run it directly instead of using `npm run
e2e`.
Also adds support for the following flags: `--serve`, `--config`,
`--specs`, `--element-explorer`, `--webdriver-update`.
Fix#4256Fix#4478
BREAKING CHANGE: `ng e2e` no longer needs `ng serve` to be running.
This commit changes 2 things:
1. Changes remaining angular-cli package references to @angular/cli.
2. Where angular-cli was mentioned as a project name, it's been changed
to Angular CLI.
Where angular-cli was meant to mean the repository name, it's been left
unchanged.
BREAKING CHANGE: This command is being removed from the core of the CLI
There are several options for deploying CLI-based applications outside the scope of this project.
One of which being https://github.com/angular-buch/angular-cli-ghpages
This functionality is likely to return in the form of an addon/plugin in the future
Closes#867, #3993
BREAKING CHANGE:
In order to use the updated `ng lint` command, the following section will have to be added to the project's `angular-cli.json` at the root level of the json object.
```json
"lint": [
{
"files": "src/**/*.ts",
"project": "src/tsconfig.json"
},
{
"files": "e2e/**/*.ts",
"project": "e2e/tsconfig.json"
}
],
```
Alternatively, you can run `ng update`.
Fix https://github.com/angular/angular-cli/issues/4138
BREAKING CHANGE:
- `--extractCss` defaults to `false` on all `--dev` (`ng build` with no flags uses `--dev`)
- `--aot` defaults to true in `--prod`
- the alias for `--output-path` is now `-op` instead of `-o`