From 78349480af093050cb8ac1b8b367fec57c2cac75 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?S=C3=A9bastien=20Lorber?=
Your Docusaurus site did not load properly.
-A very common reason is a wrong site baseUrl configuration.
+A very common reason is a wrong site baseUrl configuration.
Current configured baseUrl = ${baseUrl} ${ baseUrl === '/' ? ' (default value)' : '' }
diff --git a/packages/docusaurus/src/client/exports/__tests__/useBaseUrl.ts b/packages/docusaurus/src/client/exports/__tests__/useBaseUrl.ts index 28a7def3b2b4..8a95e2b555d7 100644 --- a/packages/docusaurus/src/client/exports/__tests__/useBaseUrl.ts +++ b/packages/docusaurus/src/client/exports/__tests__/useBaseUrl.ts @@ -19,7 +19,7 @@ describe('useBaseUrl', () => { mockedContext.mockImplementation(() => ({ siteConfig: { baseUrl: '/', - url: 'https://v2.docusaurus.io', + url: 'https://docusaurus.io', }, })); @@ -38,7 +38,7 @@ describe('useBaseUrl', () => { 'https://site.com', ); expect(useBaseUrl('/hello/byebye', {absolute: true})).toEqual( - 'https://v2.docusaurus.io/hello/byebye', + 'https://docusaurus.io/hello/byebye', ); expect(useBaseUrl('#hello')).toEqual('#hello'); }); @@ -47,7 +47,7 @@ describe('useBaseUrl', () => { mockedContext.mockImplementation(() => ({ siteConfig: { baseUrl: '/docusaurus/', - url: 'https://v2.docusaurus.io', + url: 'https://docusaurus.io', }, })); @@ -66,7 +66,7 @@ describe('useBaseUrl', () => { 'https://site.com', ); expect(useBaseUrl('/hello/byebye', {absolute: true})).toEqual( - 'https://v2.docusaurus.io/docusaurus/hello/byebye', + 'https://docusaurus.io/docusaurus/hello/byebye', ); expect(useBaseUrl('/docusaurus/')).toEqual('/docusaurus/'); expect(useBaseUrl('/docusaurus/hello')).toEqual('/docusaurus/hello'); @@ -79,7 +79,7 @@ describe('useBaseUrlUtils().withBaseUrl()', () => { mockedContext.mockImplementation(() => ({ siteConfig: { baseUrl: '/', - url: 'https://v2.docusaurus.io', + url: 'https://docusaurus.io', }, })); const {withBaseUrl} = useBaseUrlUtils(); @@ -99,7 +99,7 @@ describe('useBaseUrlUtils().withBaseUrl()', () => { 'https://site.com', ); expect(withBaseUrl('/hello/byebye', {absolute: true})).toEqual( - 'https://v2.docusaurus.io/hello/byebye', + 'https://docusaurus.io/hello/byebye', ); expect(withBaseUrl('#hello')).toEqual('#hello'); }); @@ -108,7 +108,7 @@ describe('useBaseUrlUtils().withBaseUrl()', () => { mockedContext.mockImplementation(() => ({ siteConfig: { baseUrl: '/docusaurus/', - url: 'https://v2.docusaurus.io', + url: 'https://docusaurus.io', }, })); const {withBaseUrl} = useBaseUrlUtils(); @@ -128,7 +128,7 @@ describe('useBaseUrlUtils().withBaseUrl()', () => { 'https://site.com', ); expect(withBaseUrl('/hello/byebye', {absolute: true})).toEqual( - 'https://v2.docusaurus.io/docusaurus/hello/byebye', + 'https://docusaurus.io/docusaurus/hello/byebye', ); expect(withBaseUrl('/docusaurus/')).toEqual('/docusaurus/'); expect(withBaseUrl('/docusaurus/hello')).toEqual('/docusaurus/hello'); diff --git a/packages/docusaurus/src/server/__tests__/__snapshots__/config.test.ts.snap b/packages/docusaurus/src/server/__tests__/__snapshots__/config.test.ts.snap index 9600828797d6..5d2166940cf0 100644 --- a/packages/docusaurus/src/server/__tests__/__snapshots__/config.test.ts.snap +++ b/packages/docusaurus/src/server/__tests__/__snapshots__/config.test.ts.snap @@ -10,7 +10,7 @@ exports[`loadConfig website with useless field (wrong field) in siteConfig 1`] = "\\"favicon\\" is required These field(s) [\\"useLessField\\",] are not recognized in docusaurus.config.js. If you still want these fields to be in your configuration, put them in the 'customFields' attribute. -See https://v2.docusaurus.io/docs/docusaurus.config.js/#customfields" +See https://docusaurus.io/docs/docusaurus.config.js/#customfields" `; exports[`loadConfig website with valid siteConfig 1`] = ` diff --git a/packages/docusaurus/src/server/__tests__/__snapshots__/configValidation.test.ts.snap b/packages/docusaurus/src/server/__tests__/__snapshots__/configValidation.test.ts.snap index 2e3a7527276d..8a3b047686da 100644 --- a/packages/docusaurus/src/server/__tests__/__snapshots__/configValidation.test.ts.snap +++ b/packages/docusaurus/src/server/__tests__/__snapshots__/configValidation.test.ts.snap @@ -16,13 +16,13 @@ exports[`normalizeConfig should throw error for required fields 1`] = ` \\"stylesheets\\" must be an array These field(s) [\\"invalidField\\",] are not recognized in docusaurus.config.js. If you still want these fields to be in your configuration, put them in the 'customFields' attribute. -See https://v2.docusaurus.io/docs/docusaurus.config.js/#customfields" +See https://docusaurus.io/docs/docusaurus.config.js/#customfields" `; exports[`normalizeConfig should throw error for unknown field 1`] = ` "These field(s) [\\"invalid\\",] are not recognized in docusaurus.config.js. If you still want these fields to be in your configuration, put them in the 'customFields' attribute. -See https://v2.docusaurus.io/docs/docusaurus.config.js/#customfields" +See https://docusaurus.io/docs/docusaurus.config.js/#customfields" `; exports[`normalizeConfig should throw error if css doesn't have href 1`] = ` diff --git a/packages/docusaurus/src/server/configValidation.ts b/packages/docusaurus/src/server/configValidation.ts index 6e164b482dc8..5eaeae0e25a7 100644 --- a/packages/docusaurus/src/server/configValidation.ts +++ b/packages/docusaurus/src/server/configValidation.ts @@ -164,7 +164,7 @@ export function validateConfig( '', ); formattedError = unknownFields - ? `${formattedError}These field(s) [${unknownFields}] are not recognized in ${DEFAULT_CONFIG_FILE_NAME}.\nIf you still want these fields to be in your configuration, put them in the 'customFields' attribute.\nSee https://v2.docusaurus.io/docs/docusaurus.config.js/#customfields` + ? `${formattedError}These field(s) [${unknownFields}] are not recognized in ${DEFAULT_CONFIG_FILE_NAME}.\nIf you still want these fields to be in your configuration, put them in the 'customFields' attribute.\nSee https://docusaurus.io/docs/docusaurus.config.js/#customfields` : formattedError; throw new Error(formattedError); } else { diff --git a/packages/docusaurus/src/server/plugins/init.ts b/packages/docusaurus/src/server/plugins/init.ts index 992649f7a64c..9b2366109da0 100644 --- a/packages/docusaurus/src/server/plugins/init.ts +++ b/packages/docusaurus/src/server/plugins/init.ts @@ -59,7 +59,7 @@ export default function initPlugins({ throw new TypeError(`You supplied a wrong type of plugin. A plugin should be either string or [importPath: string, options?: object]. -For more information, visit https://v2.docusaurus.io/docs/using-plugins.`); +For more information, visit https://docusaurus.io/docs/using-plugins.`); } if (!pluginModuleImport) { diff --git a/website-1.x/blog/2019-12-30-docusaurus-2019-recap.md b/website-1.x/blog/2019-12-30-docusaurus-2019-recap.md index f8e7817c28c0..138ea82de568 100644 --- a/website-1.x/blog/2019-12-30-docusaurus-2019-recap.md +++ b/website-1.x/blog/2019-12-30-docusaurus-2019-recap.md @@ -8,7 +8,7 @@ authorTwitter: yangshunz tags: [recap] --- -2019 was a great year for Docusaurus - we've made tremendous progress on [Docusaurus 2](https://v2.docusaurus.io/). Current Docusaurus 1 users who aren't using the translations feature can feel free to check it out and [migrate](https://v2.docusaurus.io/docs/migration) to it! Otherwise we will work with you to make that happen in 2020 :) +2019 was a great year for Docusaurus - we've made tremendous progress on [Docusaurus 2](https://docusaurus.io/). Current Docusaurus 1 users who aren't using the translations feature can feel free to check it out and [migrate](https://docusaurus.io/docs/migration) to it! Otherwise we will work with you to make that happen in 2020 :) @@ -58,7 +58,7 @@ A few third-party hosting/development services also has first-class integration ## Looking Ahead -D2 has gained some traction among the [developer community](https://v2.docusaurus.io/showcase). In 2020, we want to achieve full feature parity with D1 by the first half and help the remaining Facebook projects on D1 move to D2. It would also be great if we could use Docusaurus for internal documentation, but that is a non-trivial undertaking. If you have a need for it or have some ideas, come speak with us! +D2 has gained some traction among the [developer community](https://docusaurus.io/showcase). In 2020, we want to achieve full feature parity with D1 by the first half and help the remaining Facebook projects on D1 move to D2. It would also be great if we could use Docusaurus for internal documentation, but that is a non-trivial undertaking. If you have a need for it or have some ideas, come speak with us! Huge thanks to the community for their contributions, especially the core team - [Endilie Yacop Sucipto](https://github.com/endiliey), [Alexey Pyltsyn](https://github.com/lex111), [Wei Gao](https://github.com/wgao19). Lastly, thank you [Joel Marcey](https://github.com/JoelMarcey) for starting Docusaurus and supporting the project all this time. diff --git a/website-1.x/blog/2021-01-19-docusaurus-2020-recap.md b/website-1.x/blog/2021-01-19-docusaurus-2020-recap.md index aa27e5910086..d40d416d3449 100644 --- a/website-1.x/blog/2021-01-19-docusaurus-2020-recap.md +++ b/website-1.x/blog/2021-01-19-docusaurus-2020-recap.md @@ -11,9 +11,9 @@ image: /img/docusaurus-2020-recap.png **2020 was great for Docusaurus**, despite [a regrettable start](https://docusaurus.io/blog/2020/01/07/tribute-to-endi) and a tumultuous year for everyone. -We continued to invest in [Docusaurus 2](https://v2.docusaurus.io/), and made it reach **full feature parity** with [Docusaurus 1](https://v1.docusaurus.io/). +We continued to invest in [Docusaurus 2](https://docusaurus.io/), and made it reach **full feature parity** with [Docusaurus 1](https://v1.docusaurus.io/). -We now **recommend Docusaurus 2** as the **default choice** to start a new Docusaurus project and encourage v1 users to [migrate to Docusaurus 2](https://v2.docusaurus.io/docs/migration). +We now **recommend Docusaurus 2** as the **default choice** to start a new Docusaurus project and encourage v1 users to [migrate to Docusaurus 2](https://docusaurus.io/docs/migration). We are **still in alpha**, but expect **some good news very soon**! @@ -25,7 +25,7 @@ We are **still in alpha**, but expect **some good news very soon**! We have worked on many features this year, and would like to highlight the most significant ones: -- **i18n**: easily translate your Docusaurus site, released soon! ([preview](https://github.com/facebook/docusaurus/pull/3325), [doc](https://v2.docusaurus.io/docs/next/i18n/introduction)) +- **i18n**: easily translate your Docusaurus site, released soon! ([preview](https://github.com/facebook/docusaurus/pull/3325), [doc](https://docusaurus.io/docs/next/i18n/introduction)) - **Version dropdown**: enable contextual version switch - **Versioning options**: solving the most common pain-points users had with versioning - **Contextual search**: search in the current version, use the brand-new DocSearch 3 experience @@ -46,7 +46,7 @@ The plan to [rebuild Docusaurus from scratch in 2019](https://docusaurus.io/blog ![Docusaurus v1 vs v2 npm trends](/img/blog/2020-recap/docusaurus-npm-trends.png) -Notable **projects, startups, large companies, and individuals** adopted Docusaurus 2 ([showcase](https://v2.docusaurus.io/showcase)): +Notable **projects, startups, large companies, and individuals** adopted Docusaurus 2 ([showcase](https://docusaurus.io/showcase)): - [Supabase](https://supabase.io) - [React Navigation](https://reactnavigation.org) @@ -111,7 +111,7 @@ Many blog posts have been published: The Docusaurus community continues to grow, the [Discord](https://discord.gg/docusaurus) server is quite active, and [Stack Overflow questions](https://stackoverflow.com/questions/tagged/docusaurus) keep being posted. -The **modular architecture** of Docusaurus 2 allowed the community to build and publish [third-party plugins](https://v2.docusaurus.io/community/resources#community-plugins-). As we would like to federate better our community, if you are building a plugin, please [let us know](https://github.com/facebook/docusaurus/discussions/4025). +The **modular architecture** of Docusaurus 2 allowed the community to build and publish [third-party plugins](https://docusaurus.io/community/resources#community-plugins-). As we would like to federate better our community, if you are building a plugin, please [let us know](https://github.com/facebook/docusaurus/discussions/4025). ## What's next? diff --git a/website-1.x/blog/2021-03-09-releasing-docusaurus-i18n.md b/website-1.x/blog/2021-03-09-releasing-docusaurus-i18n.md index 3c9d451deb53..eca3b6342707 100644 --- a/website-1.x/blog/2021-03-09-releasing-docusaurus-i18n.md +++ b/website-1.x/blog/2021-03-09-releasing-docusaurus-i18n.md @@ -9,7 +9,7 @@ tags: [release, i18n] image: /img/blog/2021-03-09-releasing-docusaurus-i18n/social-card.png --- -Today, we officially release **[Docusaurus 2 i18n](https://v2.docusaurus.io/docs/i18n/introduction)** ([internationalization](https://en.wikipedia.org/wiki/Internationalization_and_localization)), as part of [2.0.0-alpha.71](https://github.com/facebook/docusaurus/releases/tag/v2.0.0-alpha.71). +Today, we officially release **[Docusaurus 2 i18n](https://docusaurus.io/docs/i18n/introduction)** ([internationalization](https://en.wikipedia.org/wiki/Internationalization_and_localization)), as part of [2.0.0-alpha.71](https://github.com/facebook/docusaurus/releases/tag/v2.0.0-alpha.71). Docusaurus 2 has now reached **full feature parity with Docusaurus 1**. 🎉 And soon, after a few additional infrastructure updates and a bit more testing, the **first Docusaurus 2 beta** will be released. @@ -17,7 +17,7 @@ Docusaurus 2 has now reached **full feature parity with Docusaurus 1**. 🎉 And In this post, we will present you the **translation workflow**, explain some **design decisions** and **showcase early adopter sites** that just went live: [Jest](https://jestjs.io/), [Redwood](https://learn.redwoodjs.com/), and [Datagit](https://datagit.ir/). -We also **dogfood** the i18n support on the **Docusaurus 2 site itself**, and this post is already available in [English](https://v2.docusaurus.io/blog/2021/03/09/releasing-docusaurus-i18n) and [French](https://v2.docusaurus.io/fr/blog/2021/03/09/releasing-docusaurus-i18n)! +We also **dogfood** the i18n support on the **Docusaurus 2 site itself**, and this post is already available in [English](https://docusaurus.io/blog/2021/03/09/releasing-docusaurus-i18n) and [French](https://docusaurus.io/fr/blog/2021/03/09/releasing-docusaurus-i18n)! @@ -26,18 +26,18 @@ We also **dogfood** the i18n support on the **Docusaurus 2 site itself**, and th You can translate a Docusaurus site in **3 simple steps**: 1. **Configure**: declare the default locale and alternative locales in `docusaurus.config.js` -1. **Translate**: put the translation files at the [correct filesystem location](https://v2.docusaurus.io/docs/next/i18n/introduction#translation-files-location) +1. **Translate**: put the translation files at the [correct filesystem location](https://docusaurus.io/docs/next/i18n/introduction#translation-files-location) 1. **Deploy**: build and deploy your site using a single or multi-domain strategy The i18n support is **very flexible** and based on the **filesystem**. -The **[i18n tutorial](https://v2.docusaurus.io/docs/i18n/tutorial)** is the best way to get started, and we provide help to use **[Git](https://v2.docusaurus.io/docs/i18n/git)** or **[Crowdin](https://v2.docusaurus.io/docs/i18n/crowdin)**. +The **[i18n tutorial](https://docusaurus.io/docs/i18n/tutorial)** is the best way to get started, and we provide help to use **[Git](https://docusaurus.io/docs/i18n/git)** or **[Crowdin](https://docusaurus.io/docs/i18n/crowdin)**. ## Design decisions The goals of the Docusaurus i18n system are: -- **Simple**: just put the translated files in the [correct filesystem location](https://v2.docusaurus.io/docs/next/i18n/introduction#translation-files-location) +- **Simple**: just put the translated files in the [correct filesystem location](https://docusaurus.io/docs/next/i18n/introduction#translation-files-location) - **Flexible translation workflows**: use Git (monorepo, forks, or submodules), SaaS software, FTP - **Flexible deployment options**: single, multiple domains, or hybrid - **Modular**: allow plugin authors to provide i18n support @@ -95,4 +95,4 @@ This feature has not been an easy one, and we would like to thank everyone that Thanks for reading. -🙏 And please, add your brand new i18n sites to our [showcase page](https://v2.docusaurus.io/showcase). We accept any all polished Docusaurus site here, and we are working on a [redesign](https://github.com/facebook/docusaurus/issues/4238) allowing you to filter sites by features. +🙏 And please, add your brand new i18n sites to our [showcase page](https://docusaurus.io/showcase). We accept any all polished Docusaurus site here, and we are working on a [redesign](https://github.com/facebook/docusaurus/issues/4238) allowing you to filter sites by features. diff --git a/website-1.x/docs/getting-started-installation.md b/website-1.x/docs/getting-started-installation.md index 9440a1b88b0e..a53bd34685cf 100644 --- a/website-1.x/docs/getting-started-installation.md +++ b/website-1.x/docs/getting-started-installation.md @@ -6,7 +6,7 @@ description: Docusaurus was designed from the ground up to be easily installed a Docusaurus was designed from the ground up to be easily installed and used to get your website up and running quickly. -> **Important Note:** we highly encourage you to use [Docusaurus 2](https://v2.docusaurus.io) instead. +> **Important Note:** we highly encourage you to use [Docusaurus 2](https://docusaurus.io) instead. ## Installing Docusaurus diff --git a/website-1.x/pages/en/index.js b/website-1.x/pages/en/index.js index 6a6d0139e381..24b2297b697a 100644 --- a/website-1.x/pages/en/index.js +++ b/website-1.x/pages/en/index.js @@ -71,7 +71,7 @@ class Index extends React.Component {We now recommend using{' '} - Docusaurus v2. + Docusaurus v2.
2.x | - Documentation + Documentation |
---|