From 9de672f858b37e00452a08763dea995e34330aa3 Mon Sep 17 00:00:00 2001 From: Joshua Chen Date: Tue, 3 May 2022 12:36:41 +0800 Subject: [PATCH] refactor(create): add i18n config in init template --- .../templates/classic/docusaurus.config.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/packages/create-docusaurus/templates/classic/docusaurus.config.js b/packages/create-docusaurus/templates/classic/docusaurus.config.js index 5cf4b168d330..cbea7b1b4b1b 100644 --- a/packages/create-docusaurus/templates/classic/docusaurus.config.js +++ b/packages/create-docusaurus/templates/classic/docusaurus.config.js @@ -19,6 +19,14 @@ const config = { organizationName: 'facebook', // Usually your GitHub org/user name. projectName: 'docusaurus', // Usually your repo name. + // Even if you don't use internalization, you can use this field to set useful + // metadata like html lang. For example, if your site is Chinese, you may want + // to replace "en" with "zh-Hans". + i18n: { + defaultLocale: 'en', + locales: ['en'], + }, + presets: [ [ 'classic',