Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: nexti18nSetup for OG tags error #3111

Merged
merged 56 commits into from
Sep 7, 2024
Merged
Show file tree
Hide file tree
Changes from 11 commits
Commits
Show all changes
56 commits
Select commit Hold shift + click to select a range
f1a57a0
initial commit
sambhavgupta0705 Jul 23, 2024
69c43f2
Merge branch 'master' into ogtags
sambhavgupta0705 Jul 23, 2024
960d694
fixes
sambhavgupta0705 Jul 23, 2024
10a2516
package.json changes
sambhavgupta0705 Jul 23, 2024
6f8e0fb
fixing local host url
sambhavgupta0705 Jul 23, 2024
e70371e
foixed caseStudies
sambhavgupta0705 Jul 23, 2024
ec0864a
home page fix
sambhavgupta0705 Jul 23, 2024
679f6bc
fixed GH button
sambhavgupta0705 Jul 23, 2024
85485e9
fixed linting
sambhavgupta0705 Jul 23, 2024
66debb3
fixed linting
sambhavgupta0705 Jul 23, 2024
96d4691
fixed githubButton
sambhavgupta0705 Jul 23, 2024
863fdc7
react-i18next
sambhavgupta0705 Aug 9, 2024
fb522bd
Merge branch 'master' into ogtags
sambhavgupta0705 Aug 9, 2024
805dbf7
backticks fix
sambhavgupta0705 Aug 9, 2024
a5506e9
Merge branch 'master' into ogtags
sambhavgupta0705 Aug 13, 2024
9b97fc0
Merge branch 'master' into ogtags
akshatnema Aug 15, 2024
5d99ef2
Merge branch 'master' into ogtags
akshatnema Aug 17, 2024
23c3f29
updated package-lock.json
akshatnema Aug 17, 2024
c404023
removed lint errors
akshatnema Aug 17, 2024
d764b8e
Merge branch 'master' into ogtags
akshatnema Aug 17, 2024
b966aff
Merge branch 'master' into ogtags
sambhavgupta0705 Aug 20, 2024
6a04253
package-lock.json
sambhavgupta0705 Aug 20, 2024
407a96a
package-lock.json changes
sambhavgupta0705 Aug 22, 2024
db5a459
package-lock.json changes2
sambhavgupta0705 Aug 22, 2024
07cbf4b
Merge branch 'master' into ogtags
sambhavgupta0705 Aug 22, 2024
46bc14b
rtesolving merge conflicts
sambhavgupta0705 Aug 29, 2024
8518729
resolving merge conflicts
sambhavgupta0705 Aug 29, 2024
23161d7
resolving merge conflicts
sambhavgupta0705 Aug 29, 2024
94560ff
resolving conflicts
sambhavgupta0705 Aug 30, 2024
56dabcc
merge conflicts
sambhavgupta0705 Aug 30, 2024
f2cd8e8
package changes
sambhavgupta0705 Aug 30, 2024
a11b129
fix package-lock
JeelRajodiya Aug 30, 2024
56cdf32
fix mdx
JeelRajodiya Aug 30, 2024
ea9048f
Merge branch 'asyncapi:master' into ogtags-package-fix
JeelRajodiya Aug 30, 2024
ef89be9
fix: date warnings
JeelRajodiya Aug 30, 2024
01fcb80
Merge branch 'asyncapi:master' into ogtags-package-fix
JeelRajodiya Aug 30, 2024
3bf1b18
Merge pull request #2 from sambhavgupta0705/ogtags-package-fix
sambhavgupta0705 Aug 31, 2024
24233a8
fixed lint errors
akshatnema Aug 31, 2024
e879cd3
fix
sambhavgupta0705 Aug 31, 2024
451f48d
Merge branch 'master' into ogtags
sambhavgupta0705 Sep 3, 2024
671b0ba
temporary commit
sambhavgupta0705 Sep 3, 2024
3bbbe4f
temporary commit
sambhavgupta0705 Sep 3, 2024
a3d0dbe
temporary commit
sambhavgupta0705 Sep 3, 2024
81fce4f
revert breaking changes
sambhavgupta0705 Sep 3, 2024
ff6c0b4
Merge branch 'master' into ogtags
sambhavgupta0705 Sep 3, 2024
5d43180
space fixes
sambhavgupta0705 Sep 3, 2024
8b88156
Merge branch 'master' into ogtags
sambhavgupta0705 Sep 3, 2024
428bf11
test
sambhavgupta0705 Sep 3, 2024
420ec89
Merge branch 'ogtags' of github.com:sambhavgupta0705/asyncapi_website…
sambhavgupta0705 Sep 3, 2024
6bc1848
test
sambhavgupta0705 Sep 3, 2024
1f20cba
Merge branch 'master' into ogtags
sambhavgupta0705 Sep 4, 2024
a1e0906
Merge branch 'master' into ogtags
sambhavgupta0705 Sep 5, 2024
62c1c2d
featured blog post file changes
sambhavgupta0705 Sep 6, 2024
bf1b1ee
Merge branch 'ogtags' of github.com:sambhavgupta0705/asyncapi_website…
sambhavgupta0705 Sep 6, 2024
cff22dd
Merge branch 'master' into ogtags
sambhavgupta0705 Sep 6, 2024
d2740c4
lint error fix
sambhavgupta0705 Sep 6, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion components/CaseStudyCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export default function CaseStudyCard({ studies = [] }: ICaseStudyCardProps) {
return (
<div className='flex flex-wrap pt-10 lg:grid lg:grid-cols-3 lg:gap-8 lg:text-center'>
{studies.map((study, index) => (
<a key={index} href={`casestudies/${study.id}`}>
<a key={index} href={`${study.id}`}>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of a, we should use Link tag to navigate internal pages of website.

Copy link
Contributor

@JeelRajodiya JeelRajodiya Aug 25, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of a, we should use Link tag to navigate internal pages of website.

Should we create a new issue for it?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

<div
className='max-w-sm overflow-hidden rounded-md border border-gray-200 bg-white p-4'
data-testid='CaseStudyCard-main'
Expand Down
2 changes: 1 addition & 1 deletion components/Head.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ export default function HeadComponent({
rssTitle = 'RSS Feed for AsyncAPI Initiative Blog',
rssLink = '/rss.xml'
}: IHeadProps) {
const url = process.env.DEPLOY_PRIME_URL || process.env.DEPLOY_URL || 'http://localhost:3000';
const url = process.env.NEXT_PUBLIC_DEPLOY_PRIME_URL || process.env.NEXT_PUBLIC_DEPLOY_URL || 'http://localhost:3000';
const appContext = useContext(AppContext);
const { path = '' } = appContext || {};
let currImage = image;
Expand Down
11 changes: 6 additions & 5 deletions components/MDX/MDX.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ import Profiles from '../Profiles';
import Remember from '../Remember';
import Sponsors from '../sponsors/Sponsors';
import Warning from '../Warning';
import { Table, TableCell, TableHeader, TableRow } from './MDXTable';
import { Table, TableBody, TableCell, TableHeader, TableRow, Thead } from './MDXTable';

let mermaidInitialized = false;

Expand Down Expand Up @@ -174,8 +174,8 @@ function Text({ content = '', className = '' }) {
/**
* @description This function returns MDX components.
*/
export function getMDXComponents() {
return {
const getMDXComponents =
{
h1: (props: React.HTMLProps<HTMLHeadingElement>) => (
<h1
{...props}
Expand Down Expand Up @@ -293,6 +293,8 @@ export function getMDXComponents() {
Tr: TableRow,
Td: TableCell,
Th: TableHeader,
Tbody: TableBody,
Thead,
Table,
Asyncapi3ChannelComparison,
Asyncapi3IdAndAddressComparison,
Expand Down Expand Up @@ -328,9 +330,8 @@ export function getMDXComponents() {
Profiles,
Visualizer
};
}

const mdxComponents = getMDXComponents();
export const mdxComponents = getMDXComponents;

interface MDXProviderProps {
children: React.ReactNode;
Expand Down
20 changes: 20 additions & 0 deletions components/MDX/MDXTable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -57,3 +57,23 @@ export function TableHeader(props: React.HTMLProps<HTMLTableCellElement>) {
/>
);
}

/**
* Renders the body of a table.
*
* @param props - The HTML props for the `<tbody>` element.
* @returns The rendered `<tbody>` element.
*/
export function TableBody(props: React.HTMLProps<HTMLTableSectionElement>) {
return <tbody {...props} className={`${props.className || ''}`} />;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lint error. Fix the spacing.

}

/**
* Renders the body of a table.
*
* @param props - The HTML props for the `<tbody>` element.
* @returns The rendered `<tbody>` element.
*/
export function Thead(props: React.HTMLProps<HTMLTableSectionElement>) {
return <thead {...props} className={`${props.className || ''}`} />;
}
3 changes: 1 addition & 2 deletions components/NewsletterSubscribe.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@ import { useState } from 'react';

import { ButtonType } from '@/types/components/buttons/ButtonPropsType';
import { HeadingLevel, HeadingTypeStyle } from '@/types/typography/Heading';

import { useTranslation } from '../utils/i18n';
import { useTranslation } from 'next-i18next';
import Button from './buttons/Button';
import Loader from './Loader';
import Heading from './typography/Heading';
Expand Down
2 changes: 1 addition & 1 deletion components/dashboard/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ export default function Header() {
href='https://github.com/asyncapi?type=source#-contribute-to-asyncapi'
target='_blank'
/>
<GithubButton className='lg:mt-0' />
<GithubButton text= 'View on Github' className='lg:mt-0' />
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
<GithubButton text= 'View on Github' className='lg:mt-0' />
<GithubButton text='View on Github' className='lg:mt-0' />

Fix the spacing.

<SlackButton className='lg:mt-0' />
</div>
</div>
Expand Down
3 changes: 1 addition & 2 deletions components/link.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
import Link from 'next/link';
import { useRouter } from 'next/router';

import { defaultLanguage, languages } from '../utils/i18n';
import i18nPaths from '../utils/i18nPaths';
import { defaultLanguage, i18nPaths, languages } from '@/utils/i18n';

interface LinkComponentProps {
children: React.ReactNode;
Expand Down
5 changes: 3 additions & 2 deletions components/navigation/NavBar.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
import Link from 'next/link';
import type { NextRouter } from 'next/router';
import { useRouter } from 'next/router';
import { useTranslation } from 'next-i18next';
import { useEffect, useState } from 'react';

import { defaultLanguage, languages, useTranslation } from '../../utils/i18n';
import i18nPaths from '../../utils/i18nPaths';
import { defaultLanguage, i18nPaths, languages } from '@/utils/i18n';

import { SearchButton } from '../AlgoliaSearch';
import AsyncAPILogo from '../AsyncAPILogo';
import GithubButton from '../buttons/GithubButton';
Expand Down
4 changes: 2 additions & 2 deletions components/newsroom/FeaturedBlogPost.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ export default function FeaturedBlogPost({ post, className = '' }: FeaturedBlogP
return (
<div className={`rounded-lg ${className}`}>
<article className='h-full rounded-lg'>
<Link href={post.slug}>
<div >
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we need this change?

Copy link
Contributor

@JeelRajodiya JeelRajodiya Jul 29, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Link was causing the hydration to fail (see screenshot)

image

The reason behind the hydration error was that we are nesting a <Link> tag within <Link> tag.

The first <Link> Tag:

<Link href={post.slug}>

The second (nested) <Link> Tag:

<Link href={post.slug}>
<span className='block' data-testid='FeaturedBlog-title'>
<Heading level={HeadingLevel.h3} typeStyle={HeadingTypeStyle.smSemibold} className='mt-2'>
{post.title}
</Heading>
<Paragraph typeStyle={ParagraphTypeStyle.sm} className='mt-3'>
<TextTruncate element='span' line={2} text={post.excerpt} />
</Paragraph>
</span>
</Link>

Both of these links has the same target (i.e. post.slug). So removing the outer Ling tag should not have any side effects.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
<div >
<div>

<span
className={
'flex h-full cursor-pointer flex-col divide-y divide-gray-200 overflow-hidden rounded-lg border border-gray-200 shadow-md transition-all duration-300 ease-in-out hover:shadow-lg md:max-w-164 md:flex-row'
Expand Down Expand Up @@ -117,7 +117,7 @@ export default function FeaturedBlogPost({ post, className = '' }: FeaturedBlogP
</div>
</div>
</span>
</Link>
</div>
</article>
</div>
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ In practice, the definition can become quite long. Consider the below example fr
defaultContentType: application/json

channels:
smartylighting.streetlights.1.0.event.{streetlightId}.lighting.measured:
smartylighting.streetlights.1.0.event.\{streetlightId\}.lighting.measured:
description: The topic on which measured values may be produced and consumed.
parameters:
streetlightId:
Expand Down Expand Up @@ -161,7 +161,7 @@ For example, it is possible to add a key for Kafka messages:

...
channels:
smartylighting.streetlights.1.0.event.{streetlightId}.lighting.measured:
smartylighting.streetlights.1.0.event.\{streetlightId\}.lighting.measured:
description: The topic on which measured values may be produced and consumed.
parameters:
streetlightId:
Expand Down Expand Up @@ -219,4 +219,4 @@ Many other official projects of the AsyncAPI team are still in the alpha or beta

If you want to dive a bit deeper, I recommend having a look at the recording of the AsyncAPI conference in November 2021. There were many interesting talks on how AsyncAPI can be used in projects and with other tools. For more details on how to use schemas, schema registries, and API registries with AsyncAPI, listen to my conference talk below.

<YouTube id="37X4Hbu0bSQ" />
<YouTube id="37X4Hbu0bSQ" />
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@ The growth and adoption of web-based APIs is key to the transformational technol
To illustrate, assume we have a project management API with the following interactions:

1. Create a project (e.g. POST /projects)
1. Create a new task (e.g. POST /projects/{projectId}/tasks)
1. Assign the task to someone on our team (e.g. POST /tasks/{taskId}/assignees)
1. The assignee marks the task as complete (e.g. PUT /tasks/{taskId})
1. Create a new task (e.g. POST /projects/\{projectId\}/tasks)
1. Assign the task to someone on our team (e.g. POST /tasks/\{taskId\}/assignees)
1. The assignee marks the task as complete (e.g. PUT /tasks/\{taskId\})

An API following this design works if design of the user interface closely mirrors those endpoints. But suppose an additional application requirement is to ‘automatically’ update a task’s status when marked complete by another user. With a request/response web-API, an option is to incessantly poll a status API on the chance a status might have changed. This is both cumbersome and error-prone.
Instead of polling, we can introduce an __event-driven architecture__.
Expand Down Expand Up @@ -74,4 +74,3 @@ As API designers, we must strive to use all available tools to offer a better de
1. How will my API consumers benefit from the addition of these events and how do they take advantage of them?

Let’s shift our approach from strictly request-response to thinking in terms of how our APIs can not only offer endpoints for requests, but events that enable the API to push to other services. The result will be increased innovation and more transformative APIs both within and across our LOBs.

2 changes: 1 addition & 1 deletion markdown/blog/status-update-27-20.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ We are getting a bit tired of Nunjucks and how hard it is to debug and read the

The last meeting took place on Tuesday, 23rd of June, 4PM UTC. Meeting notes are available [here](https://github.com/asyncapi/asyncapi/issues/394).

<Youtube id="LDanOihP9i4" />
<YouTube id="LDanOihP9i4" />

The next meeting is scheduled for next Tuesday, 7th of July, 8AM UTC.

Expand Down
8 changes: 4 additions & 4 deletions markdown/blog/websocket-part2.md
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ servers:
The API client must request an authentication "token" via the following REST API endpoint "GetWebSocketsToken" to connect to WebSockets Private endpoints. For more details, read https://support.kraken.com/hc/en-us/articles/360034437672-How-to-retrieve-a-WebSocket-authentication-token-Example-code-in-Python-3

The resulting token must be provided in the "token" field of any new private WebSocket feed subscription:
```

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why this Codeblock is removed?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please Go to the production url https://www.asyncapi.com/blog/websocket-part2
You will see the following error message in the blog content.

Application error: a client-side exception has occurred (see the browser console for more information).

After Fixing the i18n configuration, the most part of the site started to render on the server. So any inconsistency in the markdown can be caught during the build.

When we kept the codeblocks, the following error was occuring during build

image

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But we show that code as part of codeblock. Don't we have any solution for it?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image

It's giving a weird response inside CodeBlock.

Copy link
Contributor

@JeelRajodiya JeelRajodiya Aug 9, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sambhav has pushed solution in this commit. PTAL. Thanks.

\{
"event": "subscribe",
"subscription":
Expand All @@ -174,7 +174,7 @@ servers:
"token": "WW91ciBhdXRoZW50aWNhdGlvbiB0b2tlbiBnb2VzIGhlcmUu"
}
}
```

```

### Endpoints aka Channels
Expand Down Expand Up @@ -473,7 +473,7 @@ servers:
The API client must request an authentication "token" via the following REST API endpoint "GetWebSocketsToken" to connect to WebSockets Private endpoints. For more details read https://support.kraken.com/hc/en-us/articles/360034437672-How-to-retrieve-a-WebSocket-authentication-token-Example-code-in-Python-3

The resulting token must be provided in the "token" field of any new private WebSocket feed subscription:
```

\{
"event": "subscribe",
"subscription":
Expand All @@ -482,7 +482,7 @@ servers:
"token": "WW91ciBhdXRoZW50aWNhdGlvbiB0b2tlbiBnb2VzIGhlcmUu"
}
}
```


channels:
/:
Expand Down
2 changes: 1 addition & 1 deletion markdown/docs/tools/cli/context.md
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ Map of filesystem paths to target AsyncAPI documents.

Field Pattern | Type | Description
---|:---:|---
{contextName} | `string` | An optional string value representing filesystem path to the target AsyncAPI document.
\{contextName\} | `string` | An optional string value representing filesystem path to the target AsyncAPI document.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are cli docs maintained inside website? I think these docs are maintained from respective repo. Please clear it from @derberg.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cli docs are maintained in cli repo only so we need to make changes there

### <a name="minimalEmptyContextFile"></a>Minimal Empty Context File
Raw JSON:
Expand Down
5 changes: 5 additions & 0 deletions markdown/docs/tools/cli/metrics_collection.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
---
title: 'Metrics Collection'
weight: 20
---

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this part is handled in the workflow of cli to update the docs in the website.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was creating an error for us in rendering docs

# Metrics collection guideline

AsyncAPI **anonymously** tracks command executions to improve the specification and tools, ensuring no sensitive data reaches our servers. It aids in comprehending how AsyncAPI tools are used and adopted, facilitating ongoing improvements to our specifications and tools.
Expand Down
2 changes: 1 addition & 1 deletion markdown/docs/tools/glee/bearerToken.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ export async clientAuth({ parsedAsyncAPI, serverName }) {
}
```

Glee will utilize the `token` for server authentication, employing it in the header with the format: Authorization: Bearer {token}.
Glee will utilize the `token` for server authentication, employing it in the header with the format: Authorization: Bearer \{token\}.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please be clear that glee docs are maintained from website or not.

Copy link
Member Author

@sambhavgupta0705 sambhavgupta0705 Aug 20, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

glee docs are maintained in glee repo


### Server side

Expand Down
2 changes: 1 addition & 1 deletion markdown/docs/tools/glee/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ These scripts refer to the different stages of developing an application.

#### Create `asyncapi.yaml` file and other required directories

Create a yaml file that supports capable of receiving a "hello {name}" message with the protocol as `ws` and the channel name as `hello` the hello API will subscribe to. The operationId property is `onHello` that's the name of function and the payload property is type string publishing to that channel.
Create a yaml file that supports capable of receiving a "hello \{name\}" message with the protocol as `ws` and the channel name as `hello` the hello API will subscribe to. The operationId property is `onHello` that's the name of function and the payload property is type string publishing to that channel.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Make these changes in the docs of the cli repo.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok


```yaml
asyncapi: 3.0.0
Expand Down
16 changes: 16 additions & 0 deletions mdx-components.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
import type { MDXComponents } from 'mdx/types';

import { mdxComponents } from '@/components/MDX/MDX';

// This file allows you to provide custom React components
// to be used in MDX files. You can import and use any
// React component you want, including inline styles,
// components from other libraries, and more.

export function useMDXComponents(components: MDXComponents): MDXComponents {
return {
// Allows customizing built-in components, e.g. to add styling.
...mdxComponents,
...components
};
}
8 changes: 0 additions & 8 deletions next-i18next-static-site.config.js

This file was deleted.

10 changes: 10 additions & 0 deletions next-i18next.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
module.exports = {
i18n: {
locales: ['en', 'de'],
defaultLocale : 'en',
namespaces: ['landing-page', 'common', 'tools'],
defaultNamespace: 'landing-page',
react: { useSuspense: false },// this line
},

};
5 changes: 4 additions & 1 deletion next.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,14 @@ const nextConfig = {
}

return config;
}
},
'trailingSlash': true,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add a comment above on why this is added in next config.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@sambhavgupta0705 Can we please remove the this trainlingSlash configuration? It was in the i18n setup article, but I think it does not have any relevance with the issue.


};

const mdxConfig = withMDX({
extension: /\.mdx?$/,
providerImportSource: "@mdx-js/react",
options: {
remarkPlugins: [frontmatter, gemoji, headingId, slug, images, a11yEmoji, remarkGfm],
rehypePlugins: []
Expand Down
Loading
Loading