diff --git a/site/markdowns/docs/index.md b/site/content/docs.md similarity index 100% rename from site/markdowns/docs/index.md rename to site/content/docs.md diff --git a/site/markdowns/docs/components.md b/site/content/docs/components.md similarity index 100% rename from site/markdowns/docs/components.md rename to site/content/docs/components.md diff --git a/site/markdowns/docs/references.md b/site/content/docs/references.md similarity index 100% rename from site/markdowns/docs/references.md rename to site/content/docs/references.md diff --git a/site/content/gallery.md b/site/content/gallery.md new file mode 100644 index 00000000..d306df50 --- /dev/null +++ b/site/content/gallery.md @@ -0,0 +1,5 @@ +--- +title: Gallery +--- + +Come back soon! diff --git a/site/markdowns/tutorial-doc/learn.md b/site/content/learn.md similarity index 98% rename from site/markdowns/tutorial-doc/learn.md rename to site/content/learn.md index 97b79ce6..39a1d196 100644 --- a/site/markdowns/tutorial-doc/learn.md +++ b/site/content/learn.md @@ -10,7 +10,7 @@ Even still, there's a high learning curve before you can build a proper applicat Think about how apps are created as a frontend developer. You create some files, write some code, load some data and then simply deploy it. We don't have to worry about Docker, Kubernetes, data storage, Postgres etc. -Portal.JS logo +Portal.JS logo That's exactly what we do with Portal.js. Built in pure Javascript and React on top of the awesome Next.js framework. Here are some the cool features Portal.js brings to the table: diff --git a/site/pages/docs/[[...id]].js b/site/pages/docs/[[...id]].js deleted file mode 100644 index 11ec2bb1..00000000 --- a/site/pages/docs/[[...id]].js +++ /dev/null @@ -1,52 +0,0 @@ -import path from 'path' -import * as fs from 'fs' -import Link from 'next/link' - -import Layout from '../../components/layout' -import Prose from '../../components/prose' -import { formatMD } from '../../lib/utils' - -export default function Docs({ title, mdFile }) { - return ( - - - - - ) -} - -const postsDirectory = 'markdowns/docs' - -export async function getStaticProps({params}) { - const postId = params.id ? params.id : 'index' - const mdFilePath = path.join(postsDirectory, postId + '.md') - const mdFile = await formatMD(mdFilePath) - return { - props: { - mdFile - } - } -} - -export async function getStaticPaths() { - const fileNames = fs.readdirSync(postsDirectory) - const paths = fileNames.map(fileName => { - if (fileName == 'index.md') { - return { - params: { - id: null - } - } - } else { - return { - params: { - id: [ fileName.replace(/\.md$/, '') ] - } - } - } - }) - return { - paths: paths, - fallback: false - } -} diff --git a/site/pages/gallery.js b/site/pages/gallery.js deleted file mode 100644 index 72433701..00000000 --- a/site/pages/gallery.js +++ /dev/null @@ -1,13 +0,0 @@ -import Layout from '../components/layout' -import Prose from '../components/prose' - -export default function Gallery() { - - return ( - - -

Come back soon!

-
-
- ) -} diff --git a/site/pages/learn.js b/site/pages/learn.js deleted file mode 100644 index 10a8a6b1..00000000 --- a/site/pages/learn.js +++ /dev/null @@ -1,30 +0,0 @@ -import Link from 'next/link' -import path from 'path' - -import Layout from '../components/layout' -import Prose from '../components/prose' -import { formatMD } from '../lib/utils' - -export default function Docs({ mdFile }) { - return ( - - -

- - - -

-
-
- ) -} - -export async function getStaticProps() { - const mdFilePath = path.join(process.cwd(), "markdowns/tutorial-doc/learn.md") - const mdFile = await formatMD(mdFilePath) - return { - props: { - mdFile - } - } -}