From d9308b0b167bca6620c1cf4b0550fbbcd2fa5c3d Mon Sep 17 00:00:00 2001 From: fuwn Date: Fri, 18 Jun 2021 22:45:23 +0000 Subject: =?UTF-8?q?Deploying=20to=20gh-pages=20from=20@=20Whirlsplash/site?= =?UTF-8?q?@5c723f540854581c8be53a06faa01a06319ea20a=20=F0=9F=9A=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/tutorial/create-a-page/index.html | 38 +++++++++------------------------- 1 file changed, 10 insertions(+), 28 deletions(-) (limited to 'docs/tutorial/create-a-page/index.html') diff --git a/docs/tutorial/create-a-page/index.html b/docs/tutorial/create-a-page/index.html index 3157c60..6631dfc 100644 --- a/docs/tutorial/create-a-page/index.html +++ b/docs/tutorial/create-a-page/index.html @@ -3,38 +3,20 @@ - + -Create a Page | Whirlsplash - - - - - - - - - - - +Create a Page | Whirlsplash + +
-
Skip to main content

Create a Page

Any React or Markdown file created under src/pages directory is converted into a website page:

  • src/pages/index.js -> localhost:3000/
  • src/pages/foo.md -> localhost:3000/foo
  • src/pages/foo/bar.js -> localhost:3000/foo/bar

Create a React Page#

Create a file at src/pages/my-react-page.js:

src/pages/my-react-page.js
import React from 'react';
import Layout from '@theme/Layout';
-
function HelloWorld() {
return (
<Layout>
<h1>My React page</h1>
<p>This is a React page</p>
</Layout>
);
}

A new page is now available at http://localhost:3000/my-react-page.

Create a Markdown Page#

Create a file at src/pages/my-markdown-page.md:

src/pages/my-markdown-page.md
---
title: My Markdown page
---
-
# My Markdown page
-
This is a Markdown page

A new page is now available at http://localhost:3000/my-markdown-page.

- - - - - - - - - - - +
Skip to main content

Create a Page

Any React or Markdown file created under src/pages directory is converted into a website page:

  • src/pages/index.js -> localhost:3000/
  • src/pages/foo.md -> localhost:3000/foo
  • src/pages/foo/bar.js -> localhost:3000/foo/bar

Create a React Page#

Create a file at src/pages/my-react-page.js:

src/pages/my-react-page.js
import React from 'react';import Layout from '@theme/Layout';
+function HelloWorld() {  return (    <Layout>      <h1>My React page</h1>      <p>This is a React page</p>    </Layout>  );}

A new page is now available at http://localhost:3000/my-react-page.

Create a Markdown Page#

Create a file at src/pages/my-markdown-page.md:

src/pages/my-markdown-page.md
---title: My Markdown page---
+# My Markdown page
+This is a Markdown page

A new page is now available at http://localhost:3000/my-markdown-page.

+ + \ No newline at end of file -- cgit v1.2.3