Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
1837d48
Fumadocs WIP
davidkpiano Oct 6, 2025
017718e
WIP
davidkpiano Oct 6, 2025
0a22300
WIP
davidkpiano Oct 6, 2025
2e2be30
Process highlights
davidkpiano Oct 6, 2025
e8e5a2e
WIP
davidkpiano Oct 6, 2025
87381d0
WIP
davidkpiano Oct 6, 2025
04d98c7
Image config
davidkpiano Oct 6, 2025
0cf52c9
WIP
davidkpiano Oct 6, 2025
556266f
Twoslash
davidkpiano Oct 6, 2025
bbfd8c6
WIP
davidkpiano Oct 6, 2025
1f0d5f1
Reorganize
davidkpiano Oct 6, 2025
032cacd
Create meta
davidkpiano Oct 6, 2025
2f0f6b0
Meta
davidkpiano Oct 6, 2025
d4b38c8
Add things
davidkpiano Oct 6, 2025
35a0604
Add links
davidkpiano Oct 6, 2025
ae6ef0f
Add blog
davidkpiano Oct 7, 2025
e637fd3
Update Fumadocs
davidkpiano Oct 29, 2025
13e6341
WIP
davidkpiano Oct 31, 2025
8fc31e6
WIP
davidkpiano Oct 31, 2025
c2e0c15
Add lint
davidkpiano Nov 8, 2025
c5928b5
Fix links
davidkpiano Nov 8, 2025
165b852
Fix svg
davidkpiano Nov 22, 2025
efc1660
WIP moving files around
davidkpiano Nov 25, 2025
9a5222a
Merge branch 'main' into davidkpiano/fumadocs
davidkpiano Dec 13, 2025
ab4fdc4
Moving things around to match original docs site
davidkpiano Dec 13, 2025
91f76bf
WIP
davidkpiano Dec 14, 2025
1a8c859
Add ThemedLogo
davidkpiano Dec 15, 2025
24faf52
Fix blog
davidkpiano Dec 22, 2025
4ba40f8
Landing page
davidkpiano Dec 22, 2025
24cd67a
Move fumadocs to root
davidkpiano Dec 22, 2025
0db4397
Fix callouts
davidkpiano Dec 22, 2025
19d0f04
Upgrade Next
davidkpiano Dec 22, 2025
1abf878
Update node
davidkpiano Dec 22, 2025
881f91c
Remove vercel.json
davidkpiano Dec 22, 2025
434a107
Fix unused ts error
davidkpiano Dec 22, 2025
f26e08e
Update XState Store docs
davidkpiano Dec 22, 2025
81c4852
WIP
davidkpiano Dec 22, 2025
6515f0a
Fix pages
davidkpiano Dec 22, 2025
01a98d3
Merge branch 'main' into davidkpiano/fumadocs
davidkpiano Dec 22, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
4 changes: 2 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,5 @@ yarn-error.log*
.idea
.fleet

# Fumadocs build (TEMPORARY)
fumadocs
# Next.js
.next
229 changes: 229 additions & 0 deletions .source/index.ts

Large diffs are not rendered by default.

61 changes: 61 additions & 0 deletions .source/source.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
// source.config.ts
import {
defineCollections,
defineConfig,
defineDocs,
frontmatterSchema,
metaSchema
} from "fumadocs-mdx/config";
import { transformerTwoslash } from "fumadocs-twoslash";
import {
rehypeCodeDefaultOptions,
remarkImage
} from "fumadocs-core/mdx-plugins";
import z from "zod";
var docs = defineDocs({
docs: {
schema: frontmatterSchema,
postprocess: {
includeProcessedMarkdown: true
}
},
meta: {
schema: metaSchema
}
});
var blogPosts = defineCollections({
type: "doc",
dir: "content/blog",
schema: frontmatterSchema.extend({
authors: z.array(z.string()),
date: z.iso.date().or(z.date())
})
});
var source_config_default = defineConfig({
mdxOptions: {
// MDX options
rehypeCodeOptions: {
themes: {
light: "github-light",
dark: "github-dark"
},
transformers: [
...rehypeCodeDefaultOptions.transformers ?? [],
transformerTwoslash()
]
},
remarkPlugins: [
[
remarkImage,
{
external: false
}
]
]
}
});
export {
blogPosts,
source_config_default as default,
docs
};
59 changes: 30 additions & 29 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,44 +1,45 @@
# Welcome to the Stately docs
# fumadocs

This repo contains the Stately landing page, including our blog and docs for Stately Studio and XState.
This is a Next.js application generated with
[Create Fumadocs](https://github.com/fuma-nama/fumadocs).

The site is built using [Docusaurus 2](https://docusaurus.io/).
Run development server:

We welcome any contributions to the documentation and code base.

- ✨ [Contribution guide](https://github.com/statelyai/xstate/blob/main/CONTRIBUTING.md)
- 🖊️ [The Stately Guide to Writing Docs](https://github.com/statelyai/docs/wiki)
- 🙋 [Code of conduct](https://github.com/statelyai/docs/blob/main/CODE_OF_CONDUCT.md)

## Installation

```
$ yarn
```bash
npm run dev
# or
pnpm dev
# or
yarn dev
```

## Local development
Open http://localhost:3000 with your browser to see the result.

```
$ yarn dev
```
## Explore

This command starts a local development server and opens up a browser window. Most changes are reflected live without having to restart the server.
In the project, you can see:

### Note on the index page
- `lib/source.ts`: Code for content source adapter, [`loader()`](https://fumadocs.dev/docs/headless/source-api) provides the interface to access your content.
- `lib/layout.shared.tsx`: Shared options for layouts, optional but preferred to keep.

Currently we serve the root landing page from a static file.
| Route | Description |
| ------------------------- | ------------------------------------------------------ |
| `app/(home)` | The route group for your landing page and other pages. |
| `app/docs` | The documentation layout and pages. |
| `app/api/search/route.ts` | The Route Handler for search. |

- During server side rendering (SSR) we use [`/static/index.html`](./static/index.html)
- During client side rendering (CSR) we use [`/static/landing-page/index.html`](./static/landing-page/index.html)
### Fumadocs MDX

## Build
A `source.config.ts` config file has been included, you can customise different options like frontmatter schema.

```
$ yarn build
```
Read the [Introduction](https://fumadocs.dev/docs/mdx) for further details.

This command generates static content into the `build` directory.
## Learn More

## Deployment
To learn more about Next.js and Fumadocs, take a look at the following
resources:

The docs are built and deployed when merged into `main`.
- [Next.js Documentation](https://nextjs.org/docs) - learn about Next.js
features and API.
- [Learn Next.js](https://nextjs.org/learn) - an interactive Next.js tutorial.
- [Fumadocs](https://fumadocs.dev) - learn about Fumadocs
77 changes: 77 additions & 0 deletions app/(home)/layout.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
import { baseOptions } from '@/lib/layout.shared';
import type { ReactNode } from 'react';
import { HomeLayout } from 'fumadocs-ui/layouts/home';
import { TelescopeIcon } from 'lucide-react';

export default function Layout({ children }: { children: ReactNode }) {
return (
<HomeLayout
{...baseOptions()}
links={[
{
text: 'Docs',
url: '/docs',
active: 'nested-url',
},
{
text: 'API',
url: 'https://www.jsdocs.io/package/xstate',
external: true,
},
{
text: 'Studio',
url: 'https://stately.ai/registry/projects',
external: true,
},
{
text: 'Editor',
url: 'https://stately.ai/editor',
external: true,
},
{
text: 'Discover',
url: 'https://stately.ai/registry/discover',
external: true,
icon: <TelescopeIcon size={18} />,
},
{
text: 'Blog',
url: '/blog',
active: 'nested-url',
},
{
type: 'icon',
text: 'Visit XState GitHub repository',
icon: (
<svg
width="24"
height="24"
viewBox="0 0 24 24"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M15 22V18C15.1392 16.7473 14.78 15.4901 14 14.5C17 14.5 20 12.5 20 9C20.08 7.75 19.73 6.52 19 5.5C19.28 4.35 19.28 3.15 19 2C19 2 18 2 16 3.5C13.36 3 10.64 3 8.00004 3.5C6.00004 2 5.00004 2 5.00004 2C4.70004 3.15 4.70004 4.35 5.00004 5.5C4.27191 6.51588 3.91851 7.75279 4.00004 9C4.00004 12.5 7.00004 14.5 10 14.5C9.61004 14.99 9.32004 15.55 9.15004 16.15C8.98004 16.75 8.93004 17.38 9.00004 18V22"
stroke="currentColor"
strokeWidth="2"
strokeLinecap="round"
strokeLinejoin="round"
/>
<path
d="M9 18C4.49 20 4 16 2 16"
stroke="currentColor"
strokeWidth="2"
strokeLinecap="round"
strokeLinejoin="round"
/>
</svg>
),
url: 'https://github.com/statelyai/xstate',
external: true,
},
]}
>
{children}
</HomeLayout>
);
}
Loading