Skip to content

Commit b961be3

Browse files
authoredFeb 14, 2025
Add deprecation to website (#17008)
- Adds a banner with deprecation notice - Adds a noindex meta tag to home page to remove from search - Add og meta info for when noindex is ignored
1 parent 3800660 commit b961be3

File tree

2 files changed

+18
-4
lines changed

2 files changed

+18
-4
lines changed
 

‎docusaurus/website/docusaurus.config.js

+4-4
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@
88

99
const siteConfig = {
1010
title: 'Create React App',
11-
tagline: 'Set up a modern web app by running one command.',
11+
tagline:
12+
'Create React App has been deprecated. Please visit react.dev for modern options.',
1213
url: 'https://create-react-app.dev',
1314
baseUrl: '/',
1415
projectName: 'create-react-app',
@@ -35,10 +36,9 @@ const siteConfig = {
3536
themeConfig: {
3637
image: 'img/logo-og.png',
3738
announcementBar: {
38-
id: 'support_ukraine',
39+
id: 'deprecated',
3940
content:
40-
'Support Ukraine 🇺🇦 <a target="_blank" rel="noopener noreferrer" \
41-
href="https://opensource.facebook.com/support-ukraine"> Help Provide Humanitarian Aid to Ukraine</a>.',
41+
'Create React App is deprecated. <a target="_blank" rel="noopener noreferrer" href="https://react.dev/link/cra">Read more here</a>.',
4242
backgroundColor: '#20232a',
4343
textColor: '#fff',
4444
isCloseable: false,

‎docusaurus/website/src/pages/index.js

+14
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77

88
import React from 'react';
99
import Link from '@docusaurus/Link';
10+
import Head from '@docusaurus/Head';
1011
import useDocusaurusContext from '@docusaurus/useDocusaurusContext';
1112
import useBaseUrl from '@docusaurus/useBaseUrl';
1213

@@ -44,6 +45,19 @@ function Home() {
4445
permalink={'/'}
4546
description={'Set up a modern web app by running one command.'}
4647
>
48+
<Head>
49+
<meta name="robots" content="noindex" />
50+
<title>Create React App is deprecated.</title>
51+
<meta
52+
name="description"
53+
content="Create React App is deprecated. Please see react.dev for modern options."
54+
/>
55+
<meta property="og:title" content="Create React App is deprecated." />
56+
<meta
57+
property="og:description"
58+
content="Create React App is deprecated. Please see react.dev for modern options."
59+
/>
60+
</Head>
4761
<div className={clsx('hero hero--dark', styles.heroBanner)}>
4862
<div className="container">
4963
<img

0 commit comments

Comments
 (0)
Failed to load comments.