Skip to main content

Create a Page

Add Markdown or React files to src/pages to create a standalone page:

  • src/pages/index.js β†’ localhost:3000/
  • src/pages/foo.md β†’ localhost:3000/foo
  • src/pages/foo/bar.js β†’ localhost:3000/foo/bar

Create your first 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";

export default function MyReactPage() {
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 your first Markdown Page​

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

src/pages/my-markdown-page.md
# My Markdown page

This is a Markdown page

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

Example Mermaid diagram​

Add Math​

Let f ⁣:[a,b]β†’Rf\colon[a,b]\to\R be Riemann integrable. Let F ⁣:[a,b]β†’RF\colon[a,b]\to\R be F(x)=∫{a}{x}f(t) dtF(x)=\int_\{a\}^\{x\} f(t)\,dt. Then FF is continuous, and at all xx such that ff is continuous at xx, FF is differentiable at xx with Fβ€²(x)=f(x)F'(x)=f(x).

I=∫0{2Ο€}sin⁑(x) dxI = \int_0^\{2\pi\} \sin(x)\,dx

Let f:[a,b]β†’Rf : [a, b] \to \mathbb{R} be Riemann integrable. Let F:[a,b]β†’RF : [a, b] \to \mathbb{R} be F(x)=∫axf(t) dtF(x) = \int_{a}^{x} f(t) \, dt.

Then FF is continuous, and at all xx such that ff is continuous at xx, FF is differentiable at xx with Fβ€²(x)=f(x)F'(x) = f(x).

I=∫02Ο€sin⁑(x) dxI = \int_{0}^{2\pi} \sin(x) \, dx