-
-
Notifications
You must be signed in to change notification settings - Fork 230
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add the Code of Conduct and fix hydration issues due to markdown link…
… references * Adding the CoC through submodule + symlink * Fixed hydration issues due to markdown link references
- Loading branch information
Showing
8 changed files
with
61 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Submodule dot-github
added at
46e8b7
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../../../_includes/dot-github/CODE_OF_CONDUCT.md |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
import React from 'react' | ||
import { getLayout } from '~/components/Sidebar' | ||
import fs from 'fs' | ||
import Head from 'next/head' | ||
import matter from 'gray-matter' | ||
import StyledMarkdown from '~/components/StyledMarkdown' | ||
import { SectionContext } from '~/context' | ||
|
||
export async function getStaticProps() { | ||
const block1 = fs.readFileSync('pages/overview/code-of-conduct/_index.md', 'utf-8') | ||
const { content: block1Content } = matter(block1) | ||
return { | ||
props: { | ||
blocks: [block1Content] | ||
} | ||
} | ||
} | ||
|
||
export default function ContentExample ({ blocks }: { blocks: any[] }) { | ||
const newTitle = 'Code of Conduct' | ||
|
||
return ( | ||
<SectionContext.Provider value='docs'> | ||
<Head> | ||
<title>{newTitle}</title> | ||
</Head> | ||
<StyledMarkdown markdown={blocks[0]} /> | ||
</SectionContext.Provider> | ||
) | ||
} | ||
ContentExample.getLayout = getLayout |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters