From 2bf0ccc00295486728b8301e6a171eeb090cd1b2 Mon Sep 17 00:00:00 2001 From: Joey Perrott Date: Wed, 14 Feb 2024 21:52:29 +0000 Subject: [PATCH] docs: remove unnecessary usages of aio in adev (#54445) Remove usages of aio in adev. PR Close #54445 --- .../src/app/app.config.ts | 2 +- .../src/app/app.config.ts | 2 +- adev/src/content/guide/i18n/add-package.md | 14 ++--- adev/src/content/guide/i18n/deploy.md | 14 ++--- adev/src/content/guide/i18n/example.md | 2 +- .../content/guide/i18n/format-data-locale.md | 20 +++---- .../guide/i18n/import-global-variants.md | 8 +-- adev/src/content/guide/i18n/locale-id.md | 4 +- .../content/guide/i18n/manage-marked-text.md | 10 ++-- adev/src/content/guide/i18n/merge.md | 54 +++++++++---------- adev/src/content/guide/i18n/prepare.md | 24 ++++----- .../content/guide/i18n/translation-files.md | 52 +++++++++--------- .../configs/angular-compiler-options.md | 4 +- .../tools/libraries/using-libraries.md | 16 +++--- 14 files changed, 113 insertions(+), 113 deletions(-) diff --git a/adev/src/content/examples/hierarchical-dependency-injection/src/app/app.config.ts b/adev/src/content/examples/hierarchical-dependency-injection/src/app/app.config.ts index 96587e9ada3..630e62bd72f 100644 --- a/adev/src/content/examples/hierarchical-dependency-injection/src/app/app.config.ts +++ b/adev/src/content/examples/hierarchical-dependency-injection/src/app/app.config.ts @@ -3,7 +3,7 @@ import { provideProtractorTestingSupport } from '@angular/platform-browser'; const appConfg: ApplicationConfig = { providers: [ - // required for e2e testing on aio + // required for e2e testing provideProtractorTestingSupport() ] }; diff --git a/adev/src/content/examples/providers-viewproviders/src/app/app.config.ts b/adev/src/content/examples/providers-viewproviders/src/app/app.config.ts index 9478602f4ad..a27878dd2a6 100644 --- a/adev/src/content/examples/providers-viewproviders/src/app/app.config.ts +++ b/adev/src/content/examples/providers-viewproviders/src/app/app.config.ts @@ -3,7 +3,7 @@ import { provideProtractorTestingSupport } from '@angular/platform-browser'; const appConfig: ApplicationConfig = { providers: [ - // required for e2e testing on aio + // required for e2e testing provideProtractorTestingSupport() ] }; diff --git a/adev/src/content/guide/i18n/add-package.md b/adev/src/content/guide/i18n/add-package.md index 7d244e6c9d0..e74c31e037a 100644 --- a/adev/src/content/guide/i18n/add-package.md +++ b/adev/src/content/guide/i18n/add-package.md @@ -1,6 +1,6 @@ # Add the localize package -To take advantage of the localization features of Angular, use the [Angular CLI][AioCliMain] to add the `@angular/localize` package to your project. +To take advantage of the localization features of Angular, use the [Angular CLI][CliMain] to add the `@angular/localize` package to your project. To add the `@angular/localize` package, use the following command to update the `package.json` and TypeScript configuration files in your project. @@ -8,9 +8,9 @@ To add the `@angular/localize` package, use the following command to update the It adds `types: ["@angular/localize"]` in the TypeScript configuration files as well as the reference to the type definition of `@angular/localize` at the top of the `main.ts` file. -HELPFUL: For more information about `package.json` and `tsconfig.json` files, see [Workspace npm dependencies][AioGuideNpmPackages] and [TypeScript Configuration][AioGuideTsConfig]. +HELPFUL: For more information about `package.json` and `tsconfig.json` files, see [Workspace npm dependencies][GuideNpmPackages] and [TypeScript Configuration][GuideTsConfig]. -If `@angular/localize` is not installed and you try to build a localized version of your project (for example, while using the `i18n` attributes in templates), the [Angular CLI][AioCliMain] will generate an error, which would contain the steps that you can take to enable i18n for your project. +If `@angular/localize` is not installed and you try to build a localized version of your project (for example, while using the `i18n` attributes in templates), the [Angular CLI][CliMain] will generate an error, which would contain the steps that you can take to enable i18n for your project. ## Options @@ -19,7 +19,7 @@ If `@angular/localize` is not installed and you try to build a localized version | `--project` | The name of the project. | `string` | | `--use-at-runtime` | If set, then `$localize` can be used at runtime. Also `@angular/localize` gets included in the `dependencies` section of `package.json`, rather than `devDependencies`, which is the default. | `boolean` | `false` -For more available options, see `ng add` in [Angular CLI][AioCliMain]. +For more available options, see `ng add` in [Angular CLI][CliMain]. ## What's next @@ -28,8 +28,8 @@ For more available options, see `ng add` in [Angular CLI][AioCliMain]. -[AioCliMain]: cli "CLI Overview and Command Reference | Angular" +[CliMain]: cli "CLI Overview and Command Reference | Angular" -[AioGuideNpmPackages]: reference/configs/npm-packages "Workspace npm dependencies | Angular" +[GuideNpmPackages]: reference/configs/npm-packages "Workspace npm dependencies | Angular" -[AioGuideTsConfig]: https://www.typescriptlang.org/docs/handbook/tsconfig-json.html "TypeScript Configuration" +[GuideTsConfig]: https://www.typescriptlang.org/docs/handbook/tsconfig-json.html "TypeScript Configuration" diff --git a/adev/src/content/guide/i18n/deploy.md b/adev/src/content/guide/i18n/deploy.md index 48e8b95cc6a..5f9fb37bce0 100644 --- a/adev/src/content/guide/i18n/deploy.md +++ b/adev/src/content/guide/i18n/deploy.md @@ -4,14 +4,14 @@ If `myapp` is the directory that contains the distributable files of your projec For example, your French version is located in the `myapp/fr` directory and the Spanish version is located in the `myapp/es` directory. The HTML `base` tag with the `href` attribute specifies the base URI, or URL, for relative links. -If you set the `"localize"` option in [`angular.json`][AioGuideWorkspaceConfig] workspace build configuration file to `true` or to an array of locale IDs, the CLI adjusts the base `href` for each version of the application. +If you set the `"localize"` option in [`angular.json`][GuideWorkspaceConfig] workspace build configuration file to `true` or to an array of locale IDs, the CLI adjusts the base `href` for each version of the application. To adjust the base `href` for each version of the application, the CLI adds the locale to the configured `"baseHref"`. -Specify the `"baseHref"` for each locale in your [`angular.json`][AioGuideWorkspaceConfig] workspace build configuration file. +Specify the `"baseHref"` for each locale in your [`angular.json`][GuideWorkspaceConfig] workspace build configuration file. The following example displays `"baseHref"` set to an empty string. -Also, to declare the base `href` at compile time, use the CLI `--baseHref` option with [`ng build`][AioCliBuild]. +Also, to declare the base `href` at compile time, use the CLI `--baseHref` option with [`ng build`][CliBuild]. ## Configure a server @@ -21,7 +21,7 @@ If the user has not defined a preferred language, or if the preferred language i To change the language, change your current location to another subdirectory. The change of subdirectory often occurs using a menu implemented in the application. -HELPFUL: For more information on how to deploy apps to a remote server, see [Deployment][AioGuideDeployment]. +HELPFUL: For more information on how to deploy apps to a remote server, see [Deployment][GuideDeployment]. ### Nginx example @@ -35,8 +35,8 @@ The following example displays an Apache configuration. -[AioCliBuild]: cli/build "ng build | CLI | Angular" +[CliBuild]: cli/build "ng build | CLI | Angular" -[AioGuideDeployment]: tools/cli/deployment "Deployment | Angular" +[GuideDeployment]: tools/cli/deployment "Deployment | Angular" -[AioGuideWorkspaceConfig]: reference/configs/workspace-config "Angular workspace configuration | Angular" +[GuideWorkspaceConfig]: reference/configs/workspace-config "Angular workspace configuration | Angular" diff --git a/adev/src/content/guide/i18n/example.md b/adev/src/content/guide/i18n/example.md index aaf9e4c6a74..1825b49b3c1 100644 --- a/adev/src/content/guide/i18n/example.md +++ b/adev/src/content/guide/i18n/example.md @@ -2,7 +2,7 @@ - + diff --git a/adev/src/content/guide/i18n/format-data-locale.md b/adev/src/content/guide/i18n/format-data-locale.md index 98bf6d8e76a..140e977a95d 100644 --- a/adev/src/content/guide/i18n/format-data-locale.md +++ b/adev/src/content/guide/i18n/format-data-locale.md @@ -1,14 +1,14 @@ # Format data based on locale Angular provides the following built-in data transformation [pipes](guide/pipes). -The data transformation pipes use the [`LOCALE_ID`][AioApiCoreLocaleId] token to format data based on rules of each locale. +The data transformation pipes use the [`LOCALE_ID`][ApiCoreLocaleId] token to format data based on rules of each locale. | Data transformation pipe | Details | |:--- |:--- | -| [`DatePipe`][AioApiCommonDatepipe] | Formats a date value. | -| [`CurrencyPipe`][AioApiCommonCurrencypipe] | Transforms a number into a currency string. | -| [`DecimalPipe`][AioApiCommonDecimalpipe] | Transforms a number into a decimal number string. | -| [`PercentPipe`][AioApiCommonPercentpipe] | Transforms a number into a percentage string. | +| [`DatePipe`][ApiCommonDatepipe] | Formats a date value. | +| [`CurrencyPipe`][ApiCommonCurrencypipe] | Transforms a number into a currency string. | +| [`DecimalPipe`][ApiCommonDecimalpipe] | Transforms a number into a decimal number string. | +| [`PercentPipe`][ApiCommonPercentpipe] | Transforms a number into a percentage string. | ## Use DatePipe to display the current date @@ -44,9 +44,9 @@ HELPFUL: The locale specified for the `CurrencyPipe` overrides the global `LOCAL -[AioApiCommonCurrencypipe]: api/common/CurrencyPipe "CurrencyPipe | Common - API | Angular" +[ApiCommonCurrencypipe]: api/common/CurrencyPipe "CurrencyPipe | Common - API | Angular" -[AioApiCommonDatepipe]: api/common/DatePipe "DatePipe | Common - API | Angular" -[AioApiCommonDecimalpipe]: api/common/DecimalPipe "DecimalPipe | Common - API | Angular" -[AioApiCommonPercentpipe]: api/common/PercentPipe "PercentPipe | Common - API | Angular" -[AioApiCoreLocaleId]: api/core/LOCALE_ID "LOCALE_ID | Core - API | Angular" +[ApiCommonDatepipe]: api/common/DatePipe "DatePipe | Common - API | Angular" +[ApiCommonDecimalpipe]: api/common/DecimalPipe "DecimalPipe | Common - API | Angular" +[ApiCommonPercentpipe]: api/common/PercentPipe "PercentPipe | Common - API | Angular" +[ApiCoreLocaleId]: api/core/LOCALE_ID "LOCALE_ID | Core - API | Angular" diff --git a/adev/src/content/guide/i18n/import-global-variants.md b/adev/src/content/guide/i18n/import-global-variants.md index 4ee15b65b84..e9ad9b24cb0 100644 --- a/adev/src/content/guide/i18n/import-global-variants.md +++ b/adev/src/content/guide/i18n/import-global-variants.md @@ -1,6 +1,6 @@ # Import global variants of the locale data -The [Angular CLI][AioCliMain] automatically includes locale data if you run the [`ng build`][AioCliBuild] command with the `--localize` option. +The [Angular CLI][CliMain] automatically includes locale data if you run the [`ng build`][CliBuild] command with the `--localize` option. @@ -11,7 +11,7 @@ ng build --localize HELPFUL: The initial installation of Angular already contains locale data for English in the United States \(`en-US`\). -The [Angular CLI][AioCliMain] automatically includes the locale data and sets the `LOCALE_ID` value when you use the `--localize` option with [`ng build`][AioCliBuild] command. +The [Angular CLI][CliMain] automatically includes the locale data and sets the `LOCALE_ID` value when you use the `--localize` option with [`ng build`][CliBuild] command. The `@angular/common` package on npm contains the locale data files. Global variants of the locale data are available in `@angular/common/locales/global`. @@ -24,5 +24,5 @@ For example, you could import the global variants for French \(`fr`\) in `main.t HELPFUL: In an `NgModules` application, you would import it in your `app.module`. -[AioCliMain]: cli "CLI Overview and Command Reference | Angular" -[AioCliBuild]: cli/build "ng build | CLI | Angular" +[CliMain]: cli "CLI Overview and Command Reference | Angular" +[CliBuild]: cli/build "ng build | CLI | Angular" diff --git a/adev/src/content/guide/i18n/locale-id.md b/adev/src/content/guide/i18n/locale-id.md index 3d899100cc2..e298075a168 100644 --- a/adev/src/content/guide/i18n/locale-id.md +++ b/adev/src/content/guide/i18n/locale-id.md @@ -46,7 +46,7 @@ By default, Angular uses `en-US` as the source locale of your project. To change the source locale of your project for the build, complete the following actions. -1. Open the [`angular.json`][AioGuideWorkspaceConfig] workspace build configuration file. +1. Open the [`angular.json`][GuideWorkspaceConfig] workspace build configuration file. 1. Change the source locale in the `sourceLocale` field. ## What's next @@ -55,7 +55,7 @@ To change the source locale of your project for the build, complete the followin -[AioGuideWorkspaceConfig]: reference/configs/workspace-config "Angular workspace configuration | Angular" +[GuideWorkspaceConfig]: reference/configs/workspace-config "Angular workspace configuration | Angular" [GithubAngularAngularTreeMasterPackagesCommonLocales]: "angular/packages/common/locales | angular/angular | GitHub" diff --git a/adev/src/content/guide/i18n/manage-marked-text.md b/adev/src/content/guide/i18n/manage-marked-text.md index c294e2c2705..7de4e6dbae3 100644 --- a/adev/src/content/guide/i18n/manage-marked-text.md +++ b/adev/src/content/guide/i18n/manage-marked-text.md @@ -3,9 +3,9 @@ The Angular extractor generates a file with a translation unit entry each of the following instances. * Each `i18n` attribute in a component template -* Each [`$localize`][AioApiLocalizeInitLocalize] tagged message string in component code +* Each [`$localize`][ApiLocalizeInitLocalize] tagged message string in component code -As described in [How meanings control text extraction and merges][AioGuideI18nCommonPrepareHowMeaningsControlTextExtractionAndMerges], Angular assigns each translation unit a unique ID. +As described in [How meanings control text extraction and merges][GuideI18nCommonPrepareHowMeaningsControlTextExtractionAndMerges], Angular assigns each translation unit a unique ID. The following example displays translation units with unique IDs. @@ -21,7 +21,7 @@ Most developers don't need to use a custom ID. If you want to use a unique syntax to convey additional metadata, use a custom ID. Additional metadata may include the library, component, or area of the application in which the text appears. -To specify a custom ID in the `i18n` attribute or [`$localize`][AioApiLocalizeInitLocalize] tagged message string, use the `@@` prefix. +To specify a custom ID in the `i18n` attribute or [`$localize`][ApiLocalizeInitLocalize] tagged message string, use the `@@` prefix. The following example defines the `introductionHeader` custom ID in a heading element. @@ -93,6 +93,6 @@ Both elements now use the same translation \(`Bonjour`\), because both were defi -[AioApiLocalizeInitLocalize]: api/localize/init/$localize "$localize | init - localize - API | Angular" +[ApiLocalizeInitLocalize]: api/localize/init/$localize "$localize | init - localize - API | Angular" -[AioGuideI18nCommonPrepareHowMeaningsControlTextExtractionAndMerges]: guide/i18n/prepare#h1-example "How meanings control text extraction and merges - Prepare components for translations | Angular" +[GuideI18nCommonPrepareHowMeaningsControlTextExtractionAndMerges]: guide/i18n/prepare#h1-example "How meanings control text extraction and merges - Prepare components for translations | Angular" diff --git a/adev/src/content/guide/i18n/merge.md b/adev/src/content/guide/i18n/merge.md index 57f50a919c5..caf0bdf9dc4 100644 --- a/adev/src/content/guide/i18n/merge.md +++ b/adev/src/content/guide/i18n/merge.md @@ -2,7 +2,7 @@ To merge the completed translations into your project, complete the following actions -1. Use the [Angular CLI][AioCliMain] to build a copy of the distributable files of your project +1. Use the [Angular CLI][CliMain] to build a copy of the distributable files of your project 1. Use the `"localize"` option to replace all of the i18n messages with the valid translations and build a localized variant application. A variant application is a complete a copy of the distributable files of your application translated for a single locale. @@ -12,22 +12,22 @@ HELPFUL: For more information about how to serve each distributable copy of the For a compile-time translation of the application, the build process uses ahead-of-time (AOT) compilation to produce a small, fast, ready-to-run application. -HELPFUL: For a detailed explanation of the build process, see [Building and serving Angular apps][AioGuideBuild]. +HELPFUL: For a detailed explanation of the build process, see [Building and serving Angular apps][GuideBuild]. The build process works for translation files in the `.xlf` format or in another format that Angular understands, such as `.xtb`. -For more information about translation file formats used by Angular, see [Change the source language file format][AioGuideI18nCommonTranslationFilesChangeTheSourceLanguageFileFormat] +For more information about translation file formats used by Angular, see [Change the source language file format][GuideI18nCommonTranslationFilesChangeTheSourceLanguageFileFormat] -To build a separate distributable copy of the application for each locale, [define the locales in the build configuration][AioGuideI18nCommonMergeDefineLocalesInTheBuildConfiguration] in the [`angular.json`][AioGuideWorkspaceConfig] workspace build configuration file of your project. +To build a separate distributable copy of the application for each locale, [define the locales in the build configuration][GuideI18nCommonMergeDefineLocalesInTheBuildConfiguration] in the [`angular.json`][GuideWorkspaceConfig] workspace build configuration file of your project. This method shortens the build process by removing the requirement to perform a full application build for each locale. -To [generate application variants for each locale][AioGuideI18nCommonMergeGenerateApplicationVariantsForEachLocale], use the `"localize"` option in the [`angular.json`][AioGuideWorkspaceConfig] workspace build configuration file. -Also, to [build from the command line][AioGuideI18nCommonMergeBuildFromTheCommandLine], use the [`build`][AioCliBuild] [Angular CLI][AioCliMain] command with the `--localize` option. +To [generate application variants for each locale][GuideI18nCommonMergeGenerateApplicationVariantsForEachLocale], use the `"localize"` option in the [`angular.json`][GuideWorkspaceConfig] workspace build configuration file. +Also, to [build from the command line][GuideI18nCommonMergeBuildFromTheCommandLine], use the [`build`][CliBuild] [Angular CLI][CliMain] command with the `--localize` option. -HELPFUL: Optionally, [apply specific build options for just one locale][AioGuideI18nCommonMergeApplySpecificBuildOptionsForJustOneLocale] for a custom locale configuration. +HELPFUL: Optionally, [apply specific build options for just one locale][GuideI18nCommonMergeApplySpecificBuildOptionsForJustOneLocale] for a custom locale configuration. ## Define locales in the build configuration -Use the `i18n` project option in the [`angular.json`][AioGuideWorkspaceConfig] workspace build configuration file of your project to define locales for a project. +Use the `i18n` project option in the [`angular.json`][GuideWorkspaceConfig] workspace build configuration file of your project to define locales for a project. The following sub-options identify the source language and tell the compiler where to find supported translations for the project. @@ -38,13 +38,13 @@ The following sub-options identify the source language and tell the compiler whe ### `angular.json` for `en-US` and `fr` example -For example, the following excerpt of an [`angular.json`][AioGuideWorkspaceConfig] workspace build configuration file sets the source locale to `en-US` and provides the path to the French \(`fr`\) locale translation file. +For example, the following excerpt of an [`angular.json`][GuideWorkspaceConfig] workspace build configuration file sets the source locale to `en-US` and provides the path to the French \(`fr`\) locale translation file. ## Generate application variants for each locale -To use your locale definition in the build configuration, use the `"localize"` option in the [`angular.json`][AioGuideWorkspaceConfig] workspace build configuration file to tell the CLI which locales to generate for the build configuration. +To use your locale definition in the build configuration, use the `"localize"` option in the [`angular.json`][GuideWorkspaceConfig] workspace build configuration file to tell the CLI which locales to generate for the build configuration. * Set `"localize"` to `true` for all the locales previously defined in the build configuration. * Set `"localize"` to an array of a subset of the previously defined locale identifiers to build only those locale versions. @@ -68,17 +68,17 @@ Also, set the property to override other configurations. ### `angular.json` include all locales from build example -The following example displays the `"localize"` option set to `true` in the [`angular.json`][AioGuideWorkspaceConfig] workspace build configuration file, so that all locales defined in the build configuration are built. +The following example displays the `"localize"` option set to `true` in the [`angular.json`][GuideWorkspaceConfig] workspace build configuration file, so that all locales defined in the build configuration are built. ## Build from the command line -Also, use the `--localize` option with the [`ng build`][AioCliBuild] command and your existing `production` configuration. +Also, use the `--localize` option with the [`ng build`][CliBuild] command and your existing `production` configuration. The CLI builds all locales defined in the build configuration. If you set the locales in build configuration, it is similar to when you set the `"localize"` option to `true`. -HELPFUL: For more information about how to set the locales, see [Generate application variants for each locale][AioGuideI18nCommonMergeGenerateApplicationVariantsForEachLocale]. +HELPFUL: For more information about how to set the locales, see [Generate application variants for each locale][GuideI18nCommonMergeGenerateApplicationVariantsForEachLocale]. @@ -86,7 +86,7 @@ HELPFUL: For more information about how to set the locales, see [Generate applic To apply specific build options to only one locale, specify a single locale to create a custom locale-specific configuration. -IMPORTANT: Use the [Angular CLI][AioCliMain] development server \(`ng serve`\) with only a single locale. +IMPORTANT: Use the [Angular CLI][CliMain] development server \(`ng serve`\) with only a single locale. ### build for French example @@ -116,7 +116,7 @@ To configure the level of warning that is generated by the Angular compiler, spe | `ignore` | Do nothing | n/a | | `warning` | Displays the default warning in the console or shell | `Missing translation for message "{translation_text}"` | -Specify the warning level in the `options` section for the `build` target of your [`angular.json`][AioGuideWorkspaceConfig] workspace build configuration file. +Specify the warning level in the `options` section for the `build` target of your [`angular.json`][GuideWorkspaceConfig] workspace build configuration file. ### `angular.json` `error` warning example @@ -124,12 +124,12 @@ The following example displays how to set the warning level to `error`. -HELPFUL: When you compile your Angular project into an Angular application, the instances of the `i18n` attribute are replaced with instances of the [`$localize`][AioApiLocalizeInitLocalize] tagged message string. +HELPFUL: When you compile your Angular project into an Angular application, the instances of the `i18n` attribute are replaced with instances of the [`$localize`][ApiLocalizeInitLocalize] tagged message string. This means that your Angular application is translated after compilation. This also means that you can create localized versions of your Angular application without re-compiling your entire Angular project for each locale. When you translate your Angular application, the *translation transformation* replaces and reorders the parts \(static strings and expressions\) of the template literal string with strings from a collection of translations. -For more information, see [`$localize`][AioApiLocalizeInitLocalize]. +For more information, see [`$localize`][ApiLocalizeInitLocalize]. TLDR: Compile once, then translate for each locale. @@ -139,18 +139,18 @@ TLDR: Compile once, then translate for each locale. -[AioApiLocalizeInitLocalize]: api/localize/init/$localize "$localize | init - localize - API | Angular" +[ApiLocalizeInitLocalize]: api/localize/init/$localize "$localize | init - localize - API | Angular" -[AioCliMain]: cli "CLI Overview and Command Reference | Angular" -[AioCliBuild]: cli/build "ng build | CLI | Angular" +[CliMain]: cli "CLI Overview and Command Reference | Angular" +[CliBuild]: cli/build "ng build | CLI | Angular" -[AioGuideBuild]: tools/cli/build "Building and serving Angular apps | Angular" +[GuideBuild]: tools/cli/build "Building and serving Angular apps | Angular" -[AioGuideI18nCommonMergeApplySpecificBuildOptionsForJustOneLocale]: guide/i18n/merge#apply-specific-build-options-for-just-one-locale "Apply specific build options for just one locale - Merge translations into the application | Angular" -[AioGuideI18nCommonMergeBuildFromTheCommandLine]: guide/i18n/merge#build-from-the-command-line "Build from the command line - Merge translations into the application | Angular" -[AioGuideI18nCommonMergeDefineLocalesInTheBuildConfiguration]: guide/i18n/merge#define-locales-in-the-build-configuration "Define locales in the build configuration - Merge translations into the application | Angular" -[AioGuideI18nCommonMergeGenerateApplicationVariantsForEachLocale]: guide/i18n/merge#generate-application-variants-for-each-locale "Generate application variants for each locale - Merge translations into the application | Angular" +[GuideI18nCommonMergeApplySpecificBuildOptionsForJustOneLocale]: guide/i18n/merge#apply-specific-build-options-for-just-one-locale "Apply specific build options for just one locale - Merge translations into the application | Angular" +[GuideI18nCommonMergeBuildFromTheCommandLine]: guide/i18n/merge#build-from-the-command-line "Build from the command line - Merge translations into the application | Angular" +[GuideI18nCommonMergeDefineLocalesInTheBuildConfiguration]: guide/i18n/merge#define-locales-in-the-build-configuration "Define locales in the build configuration - Merge translations into the application | Angular" +[GuideI18nCommonMergeGenerateApplicationVariantsForEachLocale]: guide/i18n/merge#generate-application-variants-for-each-locale "Generate application variants for each locale - Merge translations into the application | Angular" -[AioGuideI18nCommonTranslationFilesChangeTheSourceLanguageFileFormat]: guide/i18n/translation-files#change-the-source-language-file-format "Change the source language file format - Work with translation files | Angular" +[GuideI18nCommonTranslationFilesChangeTheSourceLanguageFileFormat]: guide/i18n/translation-files#change-the-source-language-file-format "Change the source language file format - Work with translation files | Angular" -[AioGuideWorkspaceConfig]: reference/configs/workspace-config "Angular workspace configuration | Angular" +[GuideWorkspaceConfig]: reference/configs/workspace-config "Angular workspace configuration | Angular" diff --git a/adev/src/content/guide/i18n/prepare.md b/adev/src/content/guide/i18n/prepare.md index 53492780ff6..9597db3f1ab 100644 --- a/adev/src/content/guide/i18n/prepare.md +++ b/adev/src/content/guide/i18n/prepare.md @@ -77,7 +77,7 @@ To mark the title attribute for translation, complete the following action. In component code, the translation source text and the metadata are surrounded by backtick \(`\) characters. -Use the [`$localize`][AioApiLocalizeInitLocalize] tagged message string to mark a string in your code for translation. +Use the [`$localize`][ApiLocalizeInitLocalize] tagged message string to mark a string in your code for translation. @@ -95,7 +95,7 @@ The i18n metadata is surrounded by colon \(`:`\) characters and prepends the tra ### Include interpolated text -Include [interpolations](guide/templates/interpolation) in a [`$localize`][AioApiLocalizeInitLocalize] tagged message string. +Include [interpolations](guide/templates/interpolation) in a [`$localize`][ApiLocalizeInitLocalize] tagged message string. @@ -125,19 +125,19 @@ The following parameters provide context and additional information to reduce co | Description | Provide additional information or context | | Meaning | Provide the meaning or intent of the text within the specific context | -For additional information about custom IDs, see [Manage marked text with custom IDs][AioGuideI18nOptionalManageMarkedText]. +For additional information about custom IDs, see [Manage marked text with custom IDs][GuideI18nOptionalManageMarkedText]. ### Add helpful descriptions and meanings To translate a text message accurately, provide additional information or context for the translator. -Add a *description* of the text message as the value of the `i18n` attribute or [`$localize`][AioApiLocalizeInitLocalize] tagged message string. +Add a *description* of the text message as the value of the `i18n` attribute or [`$localize`][ApiLocalizeInitLocalize] tagged message string. The following example shows the value of the `i18n` attribute. -The following example shows the value of the [`$localize`][AioApiLocalizeInitLocalize] tagged message string with a description. +The following example shows the value of the [`$localize`][ApiLocalizeInitLocalize] tagged message string with a description. @@ -160,7 +160,7 @@ The following example shows how to specify that the `

` tag must be translate The result is any text marked with `site header`, as the *meaning* is translated exactly the same way. -The following code example shows the value of the [`$localize`][AioApiLocalizeInitLocalize] tagged message string with a meaning and a description. +The following code example shows the value of the [`$localize`][ApiLocalizeInitLocalize] tagged message string with a meaning and a description. @@ -210,8 +210,8 @@ An ICU clause defines the type of conditional text. | ICU clause | Details | |:--- |:--- | -| [`plural`][AioGuideI18nCommonPrepareMarkPlurals] | Mark the use of plural numbers | -| [`select`][AioGuideI18nCommonPrepareMarkAlternatesAndNestedExpressions] | Mark choices for alternate text based on your defined string values | +| [`plural`][GuideI18nCommonPrepareMarkPlurals] | Mark the use of plural numbers | +| [`select`][GuideI18nCommonPrepareMarkAlternatesAndNestedExpressions] | Mark choices for alternate text based on your defined string values | To simplify translation, use International Components for Unicode clauses \(ICU clauses\) with regular expressions. @@ -419,12 +419,12 @@ The following code example shows nested clauses based on the `gender` and `minut -[AioApiLocalizeInitLocalize]: api/localize/init/$localize "$localize | init - localize - API | Angular" +[ApiLocalizeInitLocalize]: api/localize/init/$localize "$localize | init - localize - API | Angular" -[AioGuideI18nCommonPrepareMarkAlternatesAndNestedExpressions]: guide/i18n/prepare#mark-alternates-and-nested-expressions "Mark alternates and nested expressions - Prepare templates for translation | Angular" -[AioGuideI18nCommonPrepareMarkPlurals]: guide/i18n/prepare#mark-plurals "Mark plurals - Prepare component for translation | Angular" +[GuideI18nCommonPrepareMarkAlternatesAndNestedExpressions]: guide/i18n/prepare#mark-alternates-and-nested-expressions "Mark alternates and nested expressions - Prepare templates for translation | Angular" +[GuideI18nCommonPrepareMarkPlurals]: guide/i18n/prepare#mark-plurals "Mark plurals - Prepare component for translation | Angular" -[AioGuideI18nOptionalManageMarkedText]: guide/i18n/manage-marked-text "Manage marked text with custom IDs | Angular" +[GuideI18nOptionalManageMarkedText]: guide/i18n/manage-marked-text "Manage marked text with custom IDs | Angular" [GithubAngularAngularBlobEcffc3557fe1bff9718c01277498e877ca44588dPackagesCoreSrcI18nLocaleEnTsL14L18]: "Line 14 to 18 - angular/packages/core/src/i18n/locale_en.ts | angular/angular | GitHub" diff --git a/adev/src/content/guide/i18n/translation-files.md b/adev/src/content/guide/i18n/translation-files.md index be4e5ee4a47..311b5d801fa 100644 --- a/adev/src/content/guide/i18n/translation-files.md +++ b/adev/src/content/guide/i18n/translation-files.md @@ -1,19 +1,19 @@ # Work with translation files -After you prepare a component for translation, use the [`extract-i18n`][AioCliExtractI18n] [Angular CLI][AioCliMain] command to extract the marked text in the component into a *source language* file. +After you prepare a component for translation, use the [`extract-i18n`][CliExtractI18n] [Angular CLI][CliMain] command to extract the marked text in the component into a *source language* file. -The marked text includes text marked with `i18n`, attributes marked with `i18n-`*attribute*, and text tagged with `$localize` as described in [Prepare component for translation][AioGuideI18nCommonPrepare]. +The marked text includes text marked with `i18n`, attributes marked with `i18n-`*attribute*, and text tagged with `$localize` as described in [Prepare component for translation][GuideI18nCommonPrepare]. Complete the following steps to create and update translation files for your project. -1. [Extract the source language file][AioGuideI18nCommonTranslationFilesExtractTheSourceLanguageFile]. +1. [Extract the source language file][GuideI18nCommonTranslationFilesExtractTheSourceLanguageFile]. 1. Optionally, change the location, format, and name. -1. Copy the source language file to [create a translation file for each language][AioGuideI18nCommonTranslationFilesCreateATranslationFileForEachLanguage]. -1. [Translate each translation file][AioGuideI18nCommonTranslationFilesTranslateEachTranslationFile]. +1. Copy the source language file to [create a translation file for each language][GuideI18nCommonTranslationFilesCreateATranslationFileForEachLanguage]. +1. [Translate each translation file][GuideI18nCommonTranslationFilesTranslateEachTranslationFile]. 1. Translate plurals and alternate expressions separately. - 1. [Translate plurals][AioGuideI18nCommonTranslationFilesTranslatePlurals]. - 1. [Translate alternate expressions][AioGuideI18nCommonTranslationFilesTranslateAlternateExpressions]. - 1. [Translate nested expressions][AioGuideI18nCommonTranslationFilesTranslateNestedExpressions]. + 1. [Translate plurals][GuideI18nCommonTranslationFilesTranslatePlurals]. + 1. [Translate alternate expressions][GuideI18nCommonTranslationFilesTranslateAlternateExpressions]. + 1. [Translate nested expressions][GuideI18nCommonTranslationFilesTranslateNestedExpressions]. ## Extract the source language file @@ -28,7 +28,7 @@ To extract the source language file, complete the following actions. The `extract-i18n` command creates a source language file named `messages.xlf` in the root directory of your project. For more information about the XML Localization Interchange File Format \(XLIFF, version 1.2\), see [XLIFF][WikipediaWikiXliff]. -Use the following [`extract-i18n`][AioCliExtractI18n] command options to change the source language file location, format, and file name. +Use the following [`extract-i18n`][CliExtractI18n] command options to change the source language file location, format, and file name. | Command option | Details | |:--- |:--- | @@ -82,7 +82,7 @@ The following example demonstrates naming the output file. To create a translation file for a locale or language, complete the following actions. -1. [Extract the source language file][AioGuideI18nCommonTranslationFilesExtractTheSourceLanguageFile]. +1. [Extract the source language file][GuideI18nCommonTranslationFilesExtractTheSourceLanguageFile]. 1. Make a copy of the source language file to create a *translation* file for each language. 1. Rename the *translation* file to add the locale. @@ -125,7 +125,7 @@ Unless you are fluent in the language and have the time to edit translations, yo ### Translation process example for French -To demonstrate the process, review the `messages.fr.xlf` file in the [Example Angular Internationalization application][AioGuideI18nExample]. The [Example Angular Internationalization application][AioGuideI18nExample] includes a French translation for you to edit without a special XLIFF editor or knowledge of French. +To demonstrate the process, review the `messages.fr.xlf` file in the [Example Angular Internationalization application][GuideI18nExample]. The [Example Angular Internationalization application][GuideI18nExample] includes a French translation for you to edit without a special XLIFF editor or knowledge of French. The following actions describe the translation process for French. @@ -134,13 +134,13 @@ The following actions describe the translation process for French. - The `id="introductionHeader"` is a [custom ID][AioGuideI18nOptionalManageMarkedText], but without the `@@` prefix required in the source HTML. + The `id="introductionHeader"` is a [custom ID][GuideI18nOptionalManageMarkedText], but without the `@@` prefix required in the source HTML. 1. Duplicate the `... ` element in the text node, rename it to `target`, and then replace the content with the French text. - In a more complex translation, the information and context in the [description and meaning elements][AioGuideI18nCommonPrepareAddHelpfulDescriptionsAndMeanings] help you choose the right words for translation. + In a more complex translation, the information and context in the [description and meaning elements][GuideI18nCommonPrepareAddHelpfulDescriptionsAndMeanings] help you choose the right words for translation. 1. Translate the other text nodes. The following example displays the way to translate. @@ -151,7 +151,7 @@ IMPORTANT: Don't change the IDs for translation units. Each `id` attribute is generated by Angular and depends on the content of the component text and the assigned meaning. If you change either the text or the meaning, then the `id` attribute changes. -For more about managing text updates and IDs, see [custom IDs][AioGuideI18nOptionalManageMarkedText]. +For more about managing text updates and IDs, see [custom IDs][GuideI18nOptionalManageMarkedText]. ## Translate plurals @@ -222,22 +222,22 @@ The following example displays both translation units after translating. -[AioCliMain]: cli "CLI Overview and Command Reference | Angular" -[AioCliExtractI18n]: cli/extract-i18n "ng extract-i18n | CLI | Angular" +[CliMain]: cli "CLI Overview and Command Reference | Angular" +[CliExtractI18n]: cli/extract-i18n "ng extract-i18n | CLI | Angular" -[AioGuideI18nCommonPrepare]: guide/i18n/prepare "Prepare component for translation | Angular" -[AioGuideI18nCommonPrepareAddHelpfulDescriptionsAndMeanings]: guide/i18n/prepare#add-helpful-descriptions-and-meanings "Add helpful descriptions and meanings - Prepare component for translation | Angular" +[GuideI18nCommonPrepare]: guide/i18n/prepare "Prepare component for translation | Angular" +[GuideI18nCommonPrepareAddHelpfulDescriptionsAndMeanings]: guide/i18n/prepare#add-helpful-descriptions-and-meanings "Add helpful descriptions and meanings - Prepare component for translation | Angular" -[AioGuideI18nCommonTranslationFilesCreateATranslationFileForEachLanguage]: guide/i18n/translation-files#create-a-translation-file-for-each-language "Create a translation file for each language - Work with translation files | Angular" -[AioGuideI18nCommonTranslationFilesExtractTheSourceLanguageFile]: guide/i18n/translation-files#extract-the-source-language-file "Extract the source language file - Work with translation files | Angular" -[AioGuideI18nCommonTranslationFilesTranslateAlternateExpressions]: guide/i18n/translation-files#translate-alternate-expressions "Translate alternate expressions - Work with translation files | Angular" -[AioGuideI18nCommonTranslationFilesTranslateEachTranslationFile]: guide/i18n/translation-files#translate-each-translation-file "Translate each translation file - Work with translation files | Angular" -[AioGuideI18nCommonTranslationFilesTranslateNestedExpressions]: guide/i18n/translation-files#translate-nested-expressions "Translate nested expressions - Work with translation files | Angular" -[AioGuideI18nCommonTranslationFilesTranslatePlurals]: guide/i18n/translation-files#translate-plurals "Translate plurals - Work with translation files | Angular" +[GuideI18nCommonTranslationFilesCreateATranslationFileForEachLanguage]: guide/i18n/translation-files#create-a-translation-file-for-each-language "Create a translation file for each language - Work with translation files | Angular" +[GuideI18nCommonTranslationFilesExtractTheSourceLanguageFile]: guide/i18n/translation-files#extract-the-source-language-file "Extract the source language file - Work with translation files | Angular" +[GuideI18nCommonTranslationFilesTranslateAlternateExpressions]: guide/i18n/translation-files#translate-alternate-expressions "Translate alternate expressions - Work with translation files | Angular" +[GuideI18nCommonTranslationFilesTranslateEachTranslationFile]: guide/i18n/translation-files#translate-each-translation-file "Translate each translation file - Work with translation files | Angular" +[GuideI18nCommonTranslationFilesTranslateNestedExpressions]: guide/i18n/translation-files#translate-nested-expressions "Translate nested expressions - Work with translation files | Angular" +[GuideI18nCommonTranslationFilesTranslatePlurals]: guide/i18n/translation-files#translate-plurals "Translate plurals - Work with translation files | Angular" -[AioGuideI18nExample]: guide/i18n/example "Example Angular Internationalization application | Angular" +[GuideI18nExample]: guide/i18n/example "Example Angular Internationalization application | Angular" -[AioGuideI18nOptionalManageMarkedText]: guide/i18n/manage-marked-text "Manage marked text with custom IDs | Angular" +[GuideI18nOptionalManageMarkedText]: guide/i18n/manage-marked-text "Manage marked text with custom IDs | Angular" [GithubGoogleAppResourceBundleWikiApplicationresourcebundlespecification]: https://github.com/google/app-resource-bundle/wiki/ApplicationResourceBundleSpecification "ApplicationResourceBundleSpecification | google/app-resource-bundle | GitHub" diff --git a/adev/src/content/reference/configs/angular-compiler-options.md b/adev/src/content/reference/configs/angular-compiler-options.md index 7433d55bb6f..8df4d77bcc4 100644 --- a/adev/src/content/reference/configs/angular-compiler-options.md +++ b/adev/src/content/reference/configs/angular-compiler-options.md @@ -80,7 +80,7 @@ Default is `false`. ### `enableI18nLegacyMessageIdFormat` Instructs the Angular template compiler to create legacy ids for messages that are tagged in templates by the `i18n` attribute. -See [Mark text for translations][AioGuideI18nCommonPrepareMarkTextInComponentTemplate] for more information about marking messages for localization. +See [Mark text for translations][GuideI18nCommonPrepareMarkTextInComponentTemplate] for more information about marking messages for localization. Set this option to `false` unless your project relies upon translations that were created earlier using legacy IDs. Default is `true`. @@ -227,4 +227,4 @@ The `ngc` command is a wrapper around TypeScript's `tsc` compiler command. The A Besides the configuration file, you can also use [`tsc` command line options](https://www.typescriptlang.org/docs/handbook/compiler-options.html) to configure `ngc`. -[AioGuideI18nCommonPrepareMarkTextInComponentTemplate]: guide/i18n/prepare#mark-text-in-component-template "Mark text in component template - Prepare component for translation | Angular" +[GuideI18nCommonPrepareMarkTextInComponentTemplate]: guide/i18n/prepare#mark-text-in-component-template "Mark text in component template - Prepare component for translation | Angular" diff --git a/adev/src/content/tools/libraries/using-libraries.md b/adev/src/content/tools/libraries/using-libraries.md index a0f196865c2..7c31f1116f1 100644 --- a/adev/src/content/tools/libraries/using-libraries.md +++ b/adev/src/content/tools/libraries/using-libraries.md @@ -2,11 +2,11 @@ When you build your Angular application, take advantage of sophisticated first-party libraries, as well as rich ecosystem of third-party libraries. [Angular Material][AngularMaterialMain] is an example of a sophisticated first-party library. -For links to the most popular libraries, see [Angular Resources][AioResources]. +For links to the most popular libraries, see [Angular Resources][Resources]. ## Install libraries -Libraries are published as [npm packages][AioGuideNpmPackages], usually together with schematics that integrate them with the Angular CLI. +Libraries are published as [npm packages][GuideNpmPackages], usually together with schematics that integrate them with the Angular CLI. To integrate reusable library code into an application, you need to install the package and import the provided functionality in the location you use it. For most published Angular libraries, use the `ng add ` Angular CLI command. @@ -70,7 +70,7 @@ Define more typings as needed. ## Updating libraries A library is able to be updated by the publisher, and also has individual dependencies which need to be kept current. -To check for updates to your installed libraries, use the [`ng update`][AioCliUpdate] Angular CLI command. +To check for updates to your installed libraries, use the [`ng update`][CliUpdate] Angular CLI command. Use `ng update ` Angular CLI command to update individual library versions. The Angular CLI checks the latest published release of the library, and if the latest version is newer than your installed version, downloads it and updates your `package.json` to match the latest version. @@ -82,7 +82,7 @@ See the [Angular Update Guide][AngularUpdateMain] for help. ## Adding a library to the runtime global scope If a legacy JavaScript library is not imported into an application, you may add it to the runtime global scope and load it as if it was added in a script tag. -Configure the Angular CLI to do this at build time using the `scripts` and `styles` options of the build target in the [`angular.json`][AioGuideWorkspaceConfig] workspace build configuration file. +Configure the Angular CLI to do this at build time using the `scripts` and `styles` options of the build target in the [`angular.json`][GuideWorkspaceConfig] workspace build configuration file. For example, to use the [Bootstrap 4][GetbootstrapDocs40GettingStartedIntroduction] library @@ -177,13 +177,13 @@ If you do not add the interface for the script-defined extension, your IDE shows -[AioCliUpdate]: cli/update "ng update | CLI |Angular" +[CliUpdate]: cli/update "ng update | CLI |Angular" -[AioGuideNpmPackages]: reference/configs/npm-packages "Workspace npm dependencies | Angular" +[GuideNpmPackages]: reference/configs/npm-packages "Workspace npm dependencies | Angular" -[AioGuideWorkspaceConfig]: reference/configs/workspace-config "Angular workspace configuration | Angular" +[GuideWorkspaceConfig]: reference/configs/workspace-config "Angular workspace configuration | Angular" -[AioResources]: resources "Explore Angular Resources | Angular" +[Resources]: resources "Explore Angular Resources | Angular" [AngularMaterialMain]: https://material.angular.io "Angular Material | Angular"