docs(aio): Upgrade example dependencies to Angular V6 (#23660)

PR Close #23660
This commit is contained in:
Brandon Roberts
2018-05-03 22:01:25 -05:00
committed by Igor Minar
parent 29600cbb19
commit fe7f48c1d5
6 changed files with 333 additions and 269 deletions

View File

@ -682,7 +682,7 @@ You also need to instruct the AOT compiler to use your translation configuration
* `i18nFormat`: the format of the translation file.
* `i18nLocale`: the locale id.
<code-example format="." language="ts">
```
"configurations": {
...
"fr": {
@ -694,17 +694,20 @@ You also need to instruct the AOT compiler to use your translation configuration
...
}
}
</code-example>
```
You then pass the configuration with the `ng serve` or `ng build` commands. The example below shows how to serve the French language file created in previous sections of this guide:
You then pass the configuration with the `ng serve` or `ng build` commands.
The example below shows how to serve the French language file created in previous
sections of this guide:
<code-example language="sh" class="code-shell">
ng serve --configuration=fr
</code-example>
For production builds, you define a separate `production-fr` build configuration in your `angular.json`.
For production builds, you define a separate `production-fr` build configuration in
your `angular.json`.
<code-example format="." language="ts">
```
"configurations": {
...
"production-fr": {
@ -731,7 +734,7 @@ For production builds, you define a separate `production-fr` build configuration
},
...
}
</code-example>
```
The same configuration options can also be provided through the CLI with your existing `production` configuration.
@ -781,7 +784,7 @@ compilation, the app will fail to load.
You specify the warning level in the `configurations` section your Angular CLI build configuration. The example below shows how to set the warning level to error:
<code-example format="." language="ts">
```
"configurations": {
...
"fr": {
@ -789,7 +792,7 @@ You specify the warning level in the `configurations` section your Angular CLI b
"i18nMissingTranslation": "error"
}
}
</code-example>
```
If you use the JIT compiler, specify the warning level in the compiler config at bootstrap by adding
the 'MissingTranslationStrategy' property. The example below shows how to set the warning level to