-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Description
MDX landing page
It's prolly about time MDX got a landing page. Here's some rough thoughts on what I've been thinking about. Would love to hear other's thoughts as well.
This is intended to start a discussion on what type of content would go nicely and what the basic structure could look like. We're interested in any and all thoughts.
Goals
The primary goal is to better describe MDX in a more accessible way. For less tech-savvy users it's a rough landing to visit mdxjs.com and end up directly in docs. We currently don't explain it well either (that's definitely on me).
It'd also be better to go more in depth on why MDX was created: to empower authors to write dynamic, engaging, and immersive content.
Terms
The following things I think might be good to emphasize (or something like it):
- Markdown for the component era
- Authorable format
- makes writing long-form content with components a blast 🚀
Sections
The following sections would be nice to have (maybe some are overkill or I'm missing better possible sections):
Playground
It might be better to show than tell so we could have a live editable MDX editor.
How it works
I think it'd be cool to show the three "stages". Ideally the HTML section will be actually rendered. Maybe this could even be dynamic?
- MDX
import TomatoBox from 'tomato-box'
export author = "Fred Flintstone"
export default = props => <main {...props} />
# Hello, world!
Here is a paragraph
<TomatoBox />- JSX
import TomatoBox from 'tomato-box'
const MDXLayout = props => <main {...props} />
const layoutProps = {
author: "Fred Flintstone"
}
export default function MDXContent(props) {
return (
<div name="wrapper" components={components}>
<MDXLayout {...layoutProps} {...props}>
<h1>{`Hello, world!`}</h1>
<p>{`Here is a paragraph`}</p>
<TomatoBox />
</MDXLayout>
</div>
);
}
MDXContent.isMDXComponent = true;- HTML
<div>
<main>
<h1>Hello, world!</h1>
<p>Here is a paragraph</p>
<section style="padding:20px;background-color:tomato">
This is the TomatoBox
</section>
</main>
</div>Features
Something based on the content from the features section on mdxjs.com
Use cases
- Blogging
- Documentation
- Design systems
Testimonials
Might be worthwhile talking to some happy users and get some quotes.
Why?
Something that illustrates or describes the motivation for writing MDX.
- allows you to components, including those elsewhere on the site
- easy to read and write
- decide what elements to render with which components (MDXProvider)
Projects
- MDX Deck
- Docz
- Demoboard
Tooling
Works with the tools you already use
- Next.js
- Gatsby
- Prettier
- Webpack
- Parcel
Plugins
Talk about the remark/rehype ecosystem and interesting things you can do with plugins. Potentially could even show an example.
Showcase/gallery
Images of some awesome MDX sites (#414).
Important links/data
- GitHub
- Current version
Search
Think we can use algolia for this, but would be great to incorporate a search bar since the docs are growing and should grow immensely with the new content planned for v1. Though this doesn't have to be part of the MVP.