redocus
v0.3.3
Published
A tiny static site generator using React and MDX
Downloads
15
Readme
Redocus
Redocus is an experimental package. Its API is not stable and may change without notice. Use it at your own risk.
A Node.js tool that enables you to generate static sites using React and MDX. It allows you to easily convert .mdx
files into static HTML pages with the ability to customize the rendering using React components and pass site metadata as props to the pages.
Installation
You can install the package via npm:
npm install --save-dev redocus react react-dom @mdx-js/mdx
or using yarn:
yarn add --dev redocus react react-dom @mdx-js/mdx
Usage
Once you have configured your redocus.config.js
file, you can start generating your static site by running the following command:
$ redocus --config redocus.config.js
You can also add this command to the scripts
section of your package.json
:
{
"name": "my-package",
"scripts": {
"build-pages": "redocus --config redocus.config.js"
}
}
This will process the input MDX files, apply the React components and layout, and generate the corresponding HTML files in the output directory.
That's it! You now have a static site generated using React.
Contributing
Contributions are welcome! If you find any issues or have suggestions for improvement, please open an issue or submit a pull request on the GitHub repository.
License
This project is licensed under the MIT License. See the LICENSE file for details.