-
Notifications
You must be signed in to change notification settings - Fork 64
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(docs-site): setup docusaurus site (#57)
feat(nxdoc): show full collection:identifier syntax for builders + executors feat(docs-site): implementation of mkdocs docs site feat(docs-site): setup docusaurus publishing #53
- Loading branch information
1 parent
cf7a0ff
commit a268c70
Showing
48 changed files
with
6,551 additions
and
243 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
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 |
---|---|---|
|
@@ -38,3 +38,7 @@ testem.log | |
# System Files | ||
.DS_Store | ||
Thumbs.db | ||
|
||
# Generated Docusaurus files | ||
.docusaurus/ | ||
.cache-loader/ |
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 |
---|---|---|
|
@@ -2,3 +2,4 @@ | |
|
||
/dist | ||
/coverage | ||
.docusaurus/ |
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,3 @@ | ||
module.exports = { | ||
presets: [require.resolve('@docusaurus/core/lib/babel/preset')], | ||
}; |
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,105 @@ | ||
module.exports = { | ||
title: 'nx-dotnet', | ||
tagline: 'The tagline of my site', | ||
url: 'https://nx-dotnet.github.io', | ||
baseUrl: '/nx-dotnet/', | ||
onBrokenLinks: 'throw', | ||
onBrokenMarkdownLinks: 'warn', | ||
favicon: 'img/favicon.ico', | ||
organizationName: 'nx-dotnet', // Usually your GitHub org/user name. | ||
projectName: 'nx-dotnet', // Usually your repo name. | ||
themeConfig: { | ||
navbar: { | ||
title: 'nx-dotnet', | ||
// logo: { | ||
// alt: 'nx-dotnet logo', | ||
// src: 'img/nx-dotnet-logo.png', | ||
// }, | ||
items: [ | ||
{ | ||
to: 'docs/', | ||
activeBasePath: 'docs', | ||
label: 'Docs', | ||
position: 'left', | ||
}, | ||
// { to: 'blog', label: 'Blog', position: 'left' }, | ||
{ | ||
href: 'https://github.com/nx-dotnet/nx-dotnet', | ||
label: 'GitHub', | ||
position: 'right', | ||
}, | ||
], | ||
}, | ||
footer: { | ||
style: 'dark', | ||
links: [ | ||
{ | ||
title: 'Docs', | ||
items: [ | ||
{ | ||
label: '@nx-dotnet/core', | ||
to: 'docs/core', | ||
}, | ||
{ | ||
label: '@nx-dotnet/nxdoc', | ||
to: 'docs/nxdoc/', | ||
}, | ||
], | ||
}, | ||
{ | ||
title: 'Community', | ||
items: [ | ||
{ | ||
label: 'Stack Overflow', | ||
href: 'https://stackoverflow.com/questions/tagged/nxdoc', | ||
}, | ||
{ | ||
label: 'Gitter', | ||
href: 'https://gitter.im/nx-dotnet-plugin/community', | ||
}, | ||
// { | ||
// label: 'Twitter', | ||
// href: 'https://twitter.com/docusaurus', | ||
// }, | ||
], | ||
}, | ||
{ | ||
title: 'More', | ||
items: [ | ||
// { | ||
// label: 'Blog', | ||
// to: 'blog', | ||
// }, | ||
{ | ||
label: 'GitHub', | ||
href: 'https://github.com/nx-dotnet/nx-dotnet', | ||
}, | ||
], | ||
}, | ||
], | ||
copyright: `Copyright © ${new Date().getFullYear()} My Project, Inc. Built with Docusaurus.`, | ||
}, | ||
}, | ||
presets: [ | ||
[ | ||
'@docusaurus/preset-classic', | ||
{ | ||
docs: { | ||
sidebarPath: require.resolve('./sidebars.js'), | ||
// Please change this to your repo. | ||
editUrl: 'https://github.com/nx-dotnet/nx-dotnet/edit/master/docs/', | ||
path: '../../docs', | ||
}, | ||
blog: { | ||
showReadingTime: true, | ||
// Please change this to your repo. | ||
editUrl: | ||
'https://github.com/nx-dotnet/nx-dotnet/edit/master/apps/docs-site/blog/', | ||
}, | ||
theme: { | ||
customCss: require.resolve('./src/css/custom.css'), | ||
}, | ||
}, | ||
], | ||
], | ||
}; |
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,8 @@ | ||
module.exports = { | ||
someSidebar: [ | ||
{ | ||
type: 'autogenerated', | ||
dirName: '.', | ||
}, | ||
], | ||
}; |
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,25 @@ | ||
/* stylelint-disable docusaurus/copyright-header */ | ||
/** | ||
* Any CSS included here will be global. The classic template | ||
* bundles Infima by default. Infima is a CSS framework designed to | ||
* work well for content-centric websites. | ||
*/ | ||
|
||
/* You can override the default Infima variables here. */ | ||
:root { | ||
--ifm-color-primary: #25c2a0; | ||
--ifm-color-primary-dark: rgb(33, 175, 144); | ||
--ifm-color-primary-darker: rgb(31, 165, 136); | ||
--ifm-color-primary-darkest: rgb(26, 136, 112); | ||
--ifm-color-primary-light: rgb(70, 203, 174); | ||
--ifm-color-primary-lighter: rgb(102, 212, 189); | ||
--ifm-color-primary-lightest: rgb(146, 224, 208); | ||
--ifm-code-font-size: 95%; | ||
} | ||
|
||
.docusaurus-highlight-code-line { | ||
background-color: rgb(72, 77, 91); | ||
display: block; | ||
margin: 0 calc(-1 * var(--ifm-pre-padding)); | ||
padding: 0 var(--ifm-pre-padding); | ||
} |
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,99 @@ | ||
import React from 'react'; | ||
import clsx from 'clsx'; | ||
import Layout from '@theme/Layout'; | ||
import Link from '@docusaurus/Link'; | ||
import useDocusaurusContext from '@docusaurus/useDocusaurusContext'; | ||
import useBaseUrl from '@docusaurus/useBaseUrl'; | ||
import styles from './styles.module.css'; | ||
|
||
const features = [ | ||
{ | ||
title: 'Easy to Use', | ||
imageUrl: 'img/undraw_docusaurus_mountain.svg', | ||
description: ( | ||
<> | ||
Docusaurus was designed from the ground up to be easily installed and | ||
used to get your website up and running quickly. | ||
</> | ||
), | ||
}, | ||
{ | ||
title: 'Focus on What Matters', | ||
imageUrl: 'img/undraw_docusaurus_tree.svg', | ||
description: ( | ||
<> | ||
Docusaurus lets you focus on your docs, and we'll do the chores. Go | ||
ahead and move your docs into the <code>docs</code> directory. | ||
</> | ||
), | ||
}, | ||
{ | ||
title: 'Powered by React', | ||
imageUrl: 'img/undraw_docusaurus_react.svg', | ||
description: ( | ||
<> | ||
Extend or customize your website layout by reusing React. Docusaurus can | ||
be extended while reusing the same header and footer. | ||
</> | ||
), | ||
}, | ||
]; | ||
|
||
function Feature({ imageUrl, title, description }) { | ||
const imgUrl = useBaseUrl(imageUrl); | ||
return ( | ||
<div className={clsx('col col--4', styles.feature)}> | ||
{imgUrl && ( | ||
<div className="text--center"> | ||
<img className={styles.featureImage} src={imgUrl} alt={title} /> | ||
</div> | ||
)} | ||
<h3>{title}</h3> | ||
<p>{description}</p> | ||
</div> | ||
); | ||
} | ||
|
||
function Home() { | ||
const context = useDocusaurusContext(); | ||
const { siteConfig = {} } = context; | ||
return ( | ||
<Layout | ||
title={`Hello from ${siteConfig.title}`} | ||
description="Description will go into a meta tag in <head />" | ||
> | ||
<header className={clsx('hero hero--primary', styles.heroBanner)}> | ||
<div className="container"> | ||
<h1 className="hero__title">{siteConfig.title}</h1> | ||
<p className="hero__subtitle">{siteConfig.tagline}</p> | ||
<div className={styles.buttons}> | ||
<Link | ||
className={clsx( | ||
'button button--outline button--secondary button--lg', | ||
styles.getStarted, | ||
)} | ||
to={useBaseUrl('docs/')} | ||
> | ||
Get Started | ||
</Link> | ||
</div> | ||
</div> | ||
</header> | ||
<main> | ||
{features && features.length > 0 && ( | ||
<section className={styles.features}> | ||
<div className="container"> | ||
<div className="row"> | ||
{features.map((props, idx) => ( | ||
<Feature key={idx} {...props} /> | ||
))} | ||
</div> | ||
</div> | ||
</section> | ||
)} | ||
</main> | ||
</Layout> | ||
); | ||
} | ||
|
||
export default Home; |
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,36 @@ | ||
/* stylelint-disable docusaurus/copyright-header */ | ||
/** | ||
* CSS files with the .module.css suffix will be treated as CSS modules | ||
* and scoped locally. | ||
*/ | ||
|
||
.heroBanner { | ||
padding: 4rem 0; | ||
text-align: center; | ||
position: relative; | ||
overflow: hidden; | ||
} | ||
|
||
@media screen and (max-width: 966px) { | ||
.heroBanner { | ||
padding: 2rem; | ||
} | ||
} | ||
|
||
.buttons { | ||
display: flex; | ||
align-items: center; | ||
justify-content: center; | ||
} | ||
|
||
.features { | ||
display: flex; | ||
align-items: center; | ||
padding: 2rem 0; | ||
width: 100%; | ||
} | ||
|
||
.featureImage { | ||
height: 200px; | ||
width: 200px; | ||
} |
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.