From 4403694e0c97d485bf232f738d4ca61f078c2fcd Mon Sep 17 00:00:00 2001 From: shaharkazaz Date: Fri, 20 Sep 2024 09:22:10 +0300 Subject: [PATCH] =?UTF-8?q?docs:=20=E2=9C=8F=EF=B8=8F=20update=20docs?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/docs/getting-started/installation.mdx | 4 ++++ docs/docs/migration/angular.mdx | 8 +++++-- docs/docs/migration/ngx.mdx | 8 +++++-- docs/sidebars.js | 26 +++++++++++----------- 4 files changed, 29 insertions(+), 17 deletions(-) diff --git a/docs/docs/getting-started/installation.mdx b/docs/docs/getting-started/installation.mdx index 803280e0c..d5b7853dc 100644 --- a/docs/docs/getting-started/installation.mdx +++ b/docs/docs/getting-started/installation.mdx @@ -8,6 +8,10 @@ import useBaseUrl from '@docusaurus/useBaseUrl'; import Tabs from '@theme/Tabs'; import TabItem from '@theme/TabItem'; +:::tip +If you already have i18n implemented in your project and are considering migrating to Transloco, be sure to check out our Migration scripts. +::: + Install the library using Angular CLI: ```bash diff --git a/docs/docs/migration/angular.mdx b/docs/docs/migration/angular.mdx index d8c1239c9..a61be48cd 100644 --- a/docs/docs/migration/angular.mdx +++ b/docs/docs/migration/angular.mdx @@ -4,14 +4,18 @@ description: Angular Migration | Transloco Angular i18n --- :::info -some manual changes might still be needed after the script ran. +Some manual changes may still be required after the script has executed. ::: The script will iterate over all your HTML files, build a translation file and will execute the replacements described below. ### Command -`ng g @jsverse/transloco:migrate` +```bash +ng g @jsverse/transloco:migrate +# On an nx workspace +nx g @jsverse/transloco:migrate +``` ### The Translation file diff --git a/docs/docs/migration/ngx.mdx b/docs/docs/migration/ngx.mdx index c6554289b..58f4b3700 100644 --- a/docs/docs/migration/ngx.mdx +++ b/docs/docs/migration/ngx.mdx @@ -4,12 +4,16 @@ description: ngx-translate Migration | Transloco Angular i18n --- :::info -some manual changes might still be needed after the script ran. +Some manual changes may still be required after the script has executed. ::: ### Command -`ng g @jsverse/transloco:migrate` +```bash +ng g @jsverse/transloco:migrate +# On an nx workspace +nx g @jsverse/transloco:migrate +``` ## What will be done? diff --git a/docs/sidebars.js b/docs/sidebars.js index d17673707..0de843e8d 100644 --- a/docs/sidebars.js +++ b/docs/sidebars.js @@ -7,6 +7,11 @@ module.exports = { 'getting-started/installation', 'getting-started/angular-compatability', 'getting-started/config-options', + { + type: 'category', + label: 'Migration', + items: ['migration/ngx', 'migration/angular'], + }, ], }, { @@ -54,14 +59,6 @@ module.exports = { type: 'doc', id: 'hack', }, - { - type: 'doc', - id: 'blog-posts', - }, - { - type: 'doc', - id: 'faq', - }, { type: 'category', label: 'Tools', @@ -101,11 +98,6 @@ module.exports = { 'schematics/component', ], }, - { - type: 'category', - label: 'Migration', - items: ['migration/ngx', 'migration/angular'], - }, { type: 'category', label: 'Recipes', @@ -115,5 +107,13 @@ module.exports = { 'recipes/google-translate-integration', ], }, + { + type: 'doc', + id: 'blog-posts', + }, + { + type: 'doc', + id: 'faq', + }, ], };