-
-
{downloads.lts}
{downloads['tagline-lts']}
-
+
-
-
{downloads.current}
{downloads['tagline-current']}
-
+
diff --git a/components/Header.tsx b/components/Header.tsx
index 9cfeb04896fa3..155e31aef49f6 100644
--- a/components/Header.tsx
+++ b/components/Header.tsx
@@ -2,7 +2,7 @@ import { useIntl } from 'react-intl';
import Image from 'next/image';
import classNames from 'classnames';
-import LocalisedLink from './LocalisedLink';
+import LocalizedLink from './LocalizedLink';
import { useLocale } from '../hooks/useLocale';
import { useNavigation } from '../hooks/useNavigation';
import { useRouter } from 'next/router';
@@ -30,7 +30,7 @@ const Header = () => {
return (
-
+
{
src="/static/images/logo.svg"
alt="Node.js"
/>
-
+
diff --git a/components/LocalisedLink.tsx b/components/LocalizedLink.tsx
similarity index 70%
rename from components/LocalisedLink.tsx
rename to components/LocalizedLink.tsx
index 78e318574fa3a..03cb82721c78d 100644
--- a/components/LocalisedLink.tsx
+++ b/components/LocalizedLink.tsx
@@ -5,19 +5,19 @@ import type { ComponentProps } from 'react';
import { useLocale } from '../hooks/useLocale';
import { linkWithLocale } from '../util/linkWithLocale';
-const LocalisedLink = (props: ComponentProps) => {
+const LocalizedLink = (props: ComponentProps) => {
const { href, children, ...extra } = props;
const { currentLocale } = useLocale();
- const localisedUrl = linkWithLocale(currentLocale.code);
+ const localizedUrl = linkWithLocale(currentLocale.code);
const finalHref = useMemo(
() =>
/^https?:\/\//.test(href.toString())
? href.toString()
- : localisedUrl(href),
- [href, localisedUrl]
+ : localizedUrl(href),
+ [href, localizedUrl]
);
return (
@@ -27,4 +27,4 @@ const LocalisedLink = (props: ComponentProps) => {
);
};
-export default LocalisedLink;
+export default LocalizedLink;
diff --git a/components/Pagination.tsx b/components/Pagination.tsx
index 3219d3249de35..dc99ab6a0b82a 100644
--- a/components/Pagination.tsx
+++ b/components/Pagination.tsx
@@ -1,21 +1,21 @@
import { FormattedMessage } from 'react-intl';
-import LocalisedLink from './LocalisedLink';
+import LocalizedLink from './LocalizedLink';
type PaginationProps = { prevSlug?: string; nextSlug?: string };
const Pagination = (props: PaginationProps) => (
);
diff --git a/components/SideNavigation.tsx b/components/SideNavigation.tsx
index 4c3dbe35134ba..b14ee9c3ac442 100644
--- a/components/SideNavigation.tsx
+++ b/components/SideNavigation.tsx
@@ -1,6 +1,6 @@
import classNames from 'classnames';
-import LocalisedLink from './LocalisedLink';
+import LocalizedLink from './LocalizedLink';
import { useLocale } from '../hooks/useLocale';
import { useNavigation } from '../hooks/useNavigation';
@@ -25,7 +25,7 @@ const SideNavigation = ({ navigationKey, context }: SideNavigationProps) => {
{sideNavigationItems.map((item, key) => (
-
- {item.text}
+ {item.text}
))}
diff --git a/hooks/useLocale.ts b/hooks/useLocale.ts
index b9ff133282fd4..96c106344c1f8 100644
--- a/hooks/useLocale.ts
+++ b/hooks/useLocale.ts
@@ -8,10 +8,10 @@ export const useLocale = () => {
const { currentLocale, availableLocales } = useContext(LocaleContext);
const { asPath } = useRouter();
- const localisedLink = linkWithLocale(currentLocale!.code);
+ const LocalizedLink = linkWithLocale(currentLocale!.code);
const localisedPath = (route: string) =>
- localisedLink(route).replace(/[#|?].*$/, '');
+ LocalizedLink(route).replace(/[#|?].*$/, '');
return {
availableLocales: availableLocales!,
diff --git a/layouts/BlogIndexLayout.tsx b/layouts/BlogIndexLayout.tsx
index b0182fbc5232a..58b08ef72d102 100644
--- a/layouts/BlogIndexLayout.tsx
+++ b/layouts/BlogIndexLayout.tsx
@@ -3,7 +3,7 @@ import type { PropsWithChildren } from 'react';
import BaseLayout from './BaseLayout';
import Pagination from '../components/Pagination';
-import LocalisedLink from '../components/LocalisedLink';
+import LocalizedLink from '../components/LocalizedLink';
import { useNextraContext } from '../hooks/useNextraContext';
import { getTimeComponent } from '../util/getTimeComponent';
@@ -25,7 +25,7 @@ const BlogIndexLayout = ({ children }: PropsWithChildren) => {
{blogData?.posts.map(post => (
-
{getTimeComponent(post.date, '%d %b')}
- {post.title}
+ {post.title}
))}
diff --git a/layouts/CategoryIndexLayout.tsx b/layouts/CategoryIndexLayout.tsx
index 0d8c0cdb07818..b8a742ed8c362 100644
--- a/layouts/CategoryIndexLayout.tsx
+++ b/layouts/CategoryIndexLayout.tsx
@@ -1,7 +1,7 @@
import type { PropsWithChildren } from 'react';
import BaseLayout from './BaseLayout';
-import LocalisedLink from '../components/LocalisedLink';
+import LocalizedLink from '../components/LocalizedLink';
import { useNextraContext } from '../hooks/useNextraContext';
import { getTimeComponent } from '../util/getTimeComponent';
@@ -17,7 +17,7 @@ const CategoryIndexLayout = ({ children }: PropsWithChildren) => {
{blogData?.posts.map(post => (
{getTimeComponent(post.date, '%d %b %y')}
- {post.title}
+ {post.title}
))}