docz
It's has never been so easy to documents your things!
Last updated 6 years ago by pedronauck .
MIT · Original npm · Tarball · package.json
$ gnpm install docz 
SYNC missed versions from official npm registry.

Chat

Docz makes it easy to write and publish beautiful interactive documentation for your code.

Create MDX files showcasing your code and Docz turns them into a live-reloading, production-ready site.

docz example

Table of Contents

Why ?

Documenting code is one of the most important and time-heavy processes when developing software.

A lot of time is spent on building and maintaining custom documentation sites.

Docz enables you to quickly create live-reloading, seo-friendly, production-ready documentation sites with MDX and customize the look, feel and behavior when required by leveraging GatsbyJS and Gatsby theme shadowing.

Start a New Project

Use create-docz-app to quickly get started :

npx create-docz-app my-docz-app
# or
yarn create docz-app my-docz-app --example typescript

Add Docz to an Existing Project

Start by adding docz as a dependency :

$ yarn add docz@next # react react-dom

# or

$ npm install docz@next # react react-dom

Note: react and react-dom will not be installed automatically. You'll have to install them yourself.

Then, add .mdx files anywhere in your project:

---
name: Button
route: /
---

import { Playground, Props } from 'docz'
import Button from './Button'

# Button

<Props of={Button} />

## Basic usage

<Playground>
  <Button type="submit">Click me</Button>
  <Button>No, click me</Button>
</Playground>

And a Button component Button.jsx:

import React from 'react'
import t from 'prop-types'

const Button = ({ children, type }) => <button type={type}>{children}</button>

Button.propTypes = {
  /**
   * This is a description for this prop.
   * Button type.
   */
  type: t.oneOf(['button', 'submit', 'reset']),
}
Button.defaultProps = {
  type: 'button',
}
export default Button

Finally, run:

yarn docz dev

This will start a local development server and open your documentation site in the browser.

Build

yarn docz build will generate a static site for your site in .docz/dist/.

You can try it out with yarn docz serve or by serving the generated site with your favorite static file server (e.g. npx serve .docz/dist).

You can have yarn docz build emit to a different directory by providing a path to the dest field in your doczrc.js or from the command line : yarn docz build --dest docs-site-directory.

Deploy

The output of docz consists of static assets only. This allows you to deploy your generated docz site with any static site hosting provider you'd like.

Start by building your site with yarn docz build, if you haven't provided a dest flag to your config then you will find your generated files in .docz/dist to copy to the server.

Examples

You can check the complete list of docz examples here.

More info on docz.site

Used by

Contributors

This project exists thanks to all the people who contribute. [Contribute].

Contributing

All kinds of contributions are very welcome and appreciated !

If you want to contribute time to docz then here's a list of suggestions to get you started :

  1. Star the project.
  2. Help people in the issues by sharing your knowledge and experience.
  3. Find and report issues.
  4. Submit PRs to help solve issues or add features.
  5. Influence the future of docz with feature requests.

If you're looking for a place to start make sure to check issues tagged with :

Good First Issue

And make sure to read the Contributing Guide before making a pull request.

You can also contribute money to help secure docz's future.

Open Collective

Current Tags

  • 2.0.0-rc.23                                ...           alpha (5 years ago)
  • 2.0.0-alpha.87                                ...           canary (5 years ago)
  • 2.4.0                                ...           latest (3 years ago)
  • 2.3.3-alpha.0                                ...           next (3 years ago)
  • 0.1.0                                ...           prerelease (7 years ago)

268 Versions

  • 2.4.0                                ...           3 years ago
  • 2.3.3-alpha.0                                ...           3 years ago
  • 2.3.2-alpha.0                                ...           5 years ago
  • 2.3.1                                ...           5 years ago
  • 2.3.1-alpha.0                                ...           5 years ago
  • 2.3.0                                ...           5 years ago
  • 2.3.0-alpha.14                                ...           5 years ago
  • 2.3.0-alpha.13                                ...           5 years ago
  • 2.3.0-alpha.12                                ...           5 years ago
  • 2.3.0-alpha.11                                ...           5 years ago
  • 2.3.0-alpha.10                                ...           5 years ago
  • 2.3.0-alpha.9                                ...           5 years ago
  • 2.3.0-alpha.8                                ...           5 years ago
  • 2.3.0-alpha.7                                ...           5 years ago
  • 2.3.0-alpha.6                                ...           5 years ago
  • 2.3.0-alpha.5                                ...           5 years ago
  • 2.3.0-alpha.4                                ...           5 years ago
  • 2.3.0-alpha.3                                ...           5 years ago
  • 2.3.0-alpha.2                                ...           5 years ago
  • 2.3.0-alpha.1                                ...           5 years ago
  • 2.3.0-alpha.0                                ...           5 years ago
  • 2.2.1-alpha.1                                ...           5 years ago
  • 2.2.1-alpha.0                                ...           5 years ago
  • 2.2.0                                ...           5 years ago
  • 2.2.0-alpha.8                                ...           5 years ago
  • 2.2.0-alpha.7                                ...           5 years ago
  • 2.2.0-alpha.6                                ...           5 years ago
  • 2.2.0-alpha.5                                ...           5 years ago
  • 2.2.0-alpha.4                                ...           5 years ago
  • 2.2.0-alpha.3                                ...           5 years ago
  • 2.2.0-alpha.2                                ...           5 years ago
  • 2.2.0-alpha.1                                ...           5 years ago
  • 2.2.0-alpha.0                                ...           5 years ago
  • 2.1.1                                ...           5 years ago
  • 2.1.0                                ...           5 years ago
  • 2.0.0                                ...           5 years ago
  • 2.0.0-rc.77                                ...           5 years ago
  • 2.0.0-rc.76                                ...           5 years ago
  • 2.0.0-rc.75                                ...           5 years ago
  • 2.0.0-rc.74                                ...           5 years ago
  • 2.0.0-rc.73                                ...           5 years ago
  • 2.0.0-rc.72                                ...           5 years ago
  • 2.0.0-rc.71                                ...           5 years ago
  • 2.0.0-rc.70                                ...           5 years ago
  • 2.0.0-rc.69                                ...           5 years ago
  • 2.0.0-rc.68                                ...           5 years ago
  • 2.0.0-rc.67                                ...           5 years ago
  • 2.0.0-rc.66                                ...           5 years ago
  • 2.0.0-rc.65                                ...           5 years ago
  • 2.0.0-rc.64                                ...           5 years ago
  • 2.0.0-rc.63                                ...           5 years ago
  • 2.0.0-rc.62                                ...           5 years ago
  • 2.0.0-rc.61                                ...           5 years ago
  • 2.0.0-rc.60                                ...           5 years ago
  • 2.0.0-rc.59                                ...           5 years ago
  • 2.0.0-rc.58                                ...           5 years ago
  • 2.0.0-rc.57                                ...           5 years ago
  • 2.0.0-rc.56                                ...           5 years ago
  • 2.0.0-rc.55                                ...           5 years ago
  • 2.0.0-rc.54                                ...           5 years ago
  • 2.0.0-rc.53                                ...           5 years ago
  • 2.0.0-rc.52                                ...           5 years ago
  • 2.0.0-rc.51                                ...           5 years ago
  • 2.0.0-rc.50                                ...           5 years ago
  • 2.0.0-rc.49                                ...           5 years ago
  • 2.0.0-rc.48                                ...           5 years ago
  • 2.0.0-rc.47                                ...           5 years ago
  • 2.0.0-rc.46                                ...           5 years ago
  • 2.0.0-rc.45                                ...           5 years ago
  • 2.0.0-rc.44                                ...           5 years ago
  • 2.0.0-rc.43                                ...           5 years ago
  • 2.0.0-rc.42                                ...           5 years ago
  • 2.0.0-rc.41                                ...           5 years ago
  • 2.0.0-rc.40                                ...           5 years ago
  • 2.0.0-rc.39                                ...           5 years ago
  • 2.0.0-rc.38                                ...           5 years ago
  • 2.0.0-rc.37                                ...           5 years ago
  • 2.0.0-rc.36                                ...           5 years ago
  • 1.3.2                                ...           5 years ago
  • 2.0.0-rc.35                                ...           5 years ago
  • 2.0.0-rc.34                                ...           5 years ago
  • 2.0.0-rc.33                                ...           5 years ago
  • 2.0.0-rc.32                                ...           5 years ago
  • 2.0.0-rc.31                                ...           5 years ago
  • 2.0.0-rc.30                                ...           5 years ago
  • 2.0.0-rc.29                                ...           5 years ago
  • 1.3.1                                ...           5 years ago
  • 1.3.0                                ...           5 years ago
  • 2.0.0-rc.28                                ...           5 years ago
  • 2.0.0-rc.27                                ...           5 years ago
  • 2.0.0-rc.25                                ...           5 years ago
  • 2.0.0-rc.24                                ...           5 years ago
  • 2.0.0-rc.23                                ...           5 years ago
  • 2.0.0-rc.21                                ...           5 years ago
  • 2.0.0-rc.20                                ...           5 years ago
  • 2.0.0-rc.19                                ...           5 years ago
  • 2.0.0-rc.18                                ...           5 years ago
  • 2.0.0-rc.17                                ...           5 years ago
  • 2.0.0-rc.16                                ...           5 years ago
  • 2.0.0-rc.15                                ...           5 years ago
  • 2.0.0-rc.14                                ...           5 years ago
  • 2.0.0-rc.13                                ...           5 years ago
  • 2.0.0-rc.12                                ...           5 years ago
  • 2.0.0-rc.11                                ...           5 years ago
  • 2.0.0-rc.10                                ...           5 years ago
  • 2.0.0-rc.9                                ...           5 years ago
  • 2.0.0-rc.8                                ...           5 years ago
  • 2.0.0-rc.7                                ...           5 years ago
  • 2.0.0-rc.6                                ...           5 years ago
  • 2.0.0-rc.5                                ...           5 years ago
  • 2.0.0-rc.4                                ...           5 years ago
  • 2.0.0-rc.3                                ...           5 years ago
  • 2.0.0-rc.2                                ...           5 years ago
  • 2.0.0-rc.1                                ...           5 years ago
  • 2.0.0-rc.0                                ...           5 years ago
  • 2.0.0-alpha.87                                ...           5 years ago
  • 2.0.0-alpha.80                                ...           5 years ago
  • 1.2.0                                ...           6 years ago
  • 1.1.0                                ...           6 years ago
  • 1.0.4                                ...           6 years ago
  • 1.0.3                                ...           6 years ago
  • 1.0.2                                ...           6 years ago
  • 1.0.1                                ...           6 years ago
  • 1.0.0                                ...           6 years ago
  • 1.0.0-rc.9                                ...           6 years ago
  • 1.0.0-rc.8                                ...           6 years ago
  • 1.0.0-rc.7                                ...           6 years ago
  • 1.0.0-rc.6                                ...           6 years ago
  • 1.0.0-rc.4                                ...           6 years ago
  • 1.0.0-rc.3                                ...           6 years ago
  • 1.0.0-rc.2                                ...           6 years ago
  • 1.0.0-beta.1                                ...           6 years ago
  • 1.0.0-beta.0                                ...           6 years ago
  • 1.0.0-alpha.0 [deprecated]           ...           6 years ago
  • 1.0.0-alpha.140 [deprecated]           ...           6 years ago
  • 1.0.0-alpha.139 [deprecated]           ...           6 years ago
  • 1.0.0-alpha.134 [deprecated]           ...           6 years ago
  • 1.0.0-alpha.133 [deprecated]           ...           6 years ago
  • 1.0.0-alpha.132 [deprecated]           ...           6 years ago
  • 1.0.0-alpha.129 [deprecated]           ...           6 years ago
  • 1.0.0-alpha.118 [deprecated]           ...           6 years ago
  • 1.0.0-alpha.107 [deprecated]           ...           6 years ago
  • 1.0.0-alpha.106 [deprecated]           ...           6 years ago
  • 1.0.0-alpha.104 [deprecated]           ...           6 years ago
  • 1.0.0-alpha.103 [deprecated]           ...           6 years ago
  • 1.0.0-alpha.102 [deprecated]           ...           6 years ago
  • 1.0.0-alpha.100 [deprecated]           ...           6 years ago
  • 1.0.0-alpha.98 [deprecated]           ...           6 years ago
  • 1.0.0-alpha.91 [deprecated]           ...           6 years ago
  • 1.0.0-rc.1.88 [deprecated]           ...           6 years ago
  • 1.0.0-rc.1.84 [deprecated]           ...           6 years ago
  • 1.0.0-alpha.76 [deprecated]           ...           6 years ago
  • 0.13.6-alpha.67 [deprecated]           ...           6 years ago
  • 0.14.0-alpha.68 [deprecated]           ...           6 years ago
  • 0.14.0-alpha.67 [deprecated]           ...           6 years ago
  • 0.14.0-alpha.66 [deprecated]           ...           6 years ago
  • 0.14.0-alpha.54 [deprecated]           ...           6 years ago
  • 0.14.0-alpha.51 [deprecated]           ...           6 years ago
  • 0.14.0-alpha.47 [deprecated]           ...           6 years ago
  • 0.14.0-alpha.44 [deprecated]           ...           6 years ago
  • 0.13.6-alpha.43 [deprecated]           ...           6 years ago
  • 0.14.0-alpha.42 [deprecated]           ...           6 years ago
  • 0.14.0-alpha.20 [deprecated]           ...           6 years ago
  • 0.13.6-alpha.20 [deprecated]           ...           6 years ago
  • 0.13.7                                ...           6 years ago
  • 0.13.6                                ...           6 years ago
  • 0.13.6-alpha.2 [deprecated]           ...           6 years ago
  • 0.13.5                                ...           6 years ago
  • 0.13.4                                ...           6 years ago
  • 0.13.3                                ...           6 years ago
  • 0.13.3-alpha.4 [deprecated]           ...           6 years ago
  • 0.13.2                                ...           6 years ago
  • 0.13.1                                ...           6 years ago
  • 0.13.0                                ...           6 years ago
  • 0.12.17-alpha.23 [deprecated]           ...           6 years ago
  • 0.12.17                                ...           6 years ago
  • 0.12.17-alpha.3 [deprecated]           ...           6 years ago
  • 0.12.17-alpha.2 [deprecated]           ...           6 years ago
  • 0.12.17-alpha.0 [deprecated]           ...           6 years ago
  • 0.12.16                                ...           6 years ago
  • 0.12.15                                ...           6 years ago
  • 0.12.14                                ...           6 years ago
  • 0.12.13                                ...           6 years ago
  • 0.12.12                                ...           6 years ago
  • 0.12.11                                ...           6 years ago
  • 0.12.10                                ...           6 years ago
  • 0.12.9                                ...           6 years ago
  • 0.12.8                                ...           6 years ago
  • 0.12.7                                ...           6 years ago
  • 0.12.6                                ...           6 years ago
  • 0.12.5                                ...           6 years ago
  • 0.12.4                                ...           6 years ago
  • 0.12.3                                ...           6 years ago
  • 0.12.2                                ...           6 years ago
  • 0.11.2                                ...           6 years ago
  • 0.11.1                                ...           6 years ago
  • 0.11.0                                ...           6 years ago
  • 0.10.3                                ...           6 years ago
  • 0.10.2                                ...           6 years ago
  • 0.10.1                                ...           6 years ago
  • 0.10.0                                ...           6 years ago
  • 0.9.6                                ...           6 years ago
  • 0.9.5                                ...           6 years ago
  • 0.9.4                                ...           6 years ago
  • 0.9.3                                ...           6 years ago
  • 0.9.2                                ...           6 years ago
  • 0.9.1                                ...           6 years ago
  • 0.9.0                                ...           6 years ago
  • 0.8.0                                ...           6 years ago
  • 0.7.1                                ...           6 years ago
  • 0.7.0                                ...           6 years ago
  • 0.6.2                                ...           6 years ago
  • 0.6.1                                ...           6 years ago
  • 0.6.0                                ...           6 years ago
  • 0.5.9                                ...           6 years ago
  • 0.5.8                                ...           6 years ago
  • 0.5.7                                ...           6 years ago
  • 0.5.6                                ...           6 years ago
  • 0.5.5                                ...           6 years ago
  • 0.5.4                                ...           6 years ago
  • 0.5.3                                ...           6 years ago
  • 0.5.2                                ...           6 years ago
  • 0.5.1                                ...           6 years ago
  • 0.5.0                                ...           6 years ago
  • 0.4.0                                ...           6 years ago
  • 0.3.4                                ...           6 years ago
  • 0.3.3                                ...           6 years ago
  • 0.3.2                                ...           6 years ago
  • 0.3.1                                ...           6 years ago
  • 0.3.0                                ...           6 years ago
  • 0.3.0-beta.0 [deprecated]           ...           6 years ago
  • 0.2.11                                ...           6 years ago
  • 0.2.10                                ...           6 years ago
  • 0.2.9                                ...           6 years ago
  • 0.2.8                                ...           6 years ago
  • 0.2.7                                ...           6 years ago
  • 0.2.6                                ...           6 years ago
  • 0.2.5                                ...           6 years ago
  • 0.2.4                                ...           6 years ago
  • 0.2.3                                ...           6 years ago
  • 0.2.2                                ...           6 years ago
  • 0.2.1                                ...           6 years ago
  • 0.2.0                                ...           7 years ago
  • 0.2.0-beta.2 [deprecated]           ...           7 years ago
  • 0.2.0-beta.1 [deprecated]           ...           7 years ago
  • 0.2.0-beta.0 [deprecated]           ...           7 years ago
  • 0.1.2-beta.6 [deprecated]           ...           7 years ago
  • 0.1.2-beta.5 [deprecated]           ...           7 years ago
  • 0.1.2-beta.4 [deprecated]           ...           7 years ago
  • 0.1.2-beta.3 [deprecated]           ...           7 years ago
  • 0.1.2-beta.2 [deprecated]           ...           7 years ago
  • 0.1.2-beta.1 [deprecated]           ...           7 years ago
  • 0.1.2-beta.0 [deprecated]           ...           7 years ago
  • 0.1.1                                ...           7 years ago
  • 0.1.1-beta.11 [deprecated]           ...           7 years ago
  • 0.1.1-beta.10 [deprecated]           ...           7 years ago
  • 0.1.1-beta.9 [deprecated]           ...           7 years ago
  • 0.1.1-beta.8 [deprecated]           ...           7 years ago
  • 0.1.1-beta.7 [deprecated]           ...           7 years ago
  • 0.1.1-beta.6 [deprecated]           ...           7 years ago
  • 0.1.1-beta.5 [deprecated]           ...           7 years ago
  • 0.1.1-beta.4 [deprecated]           ...           7 years ago
  • 0.1.1-beta.3 [deprecated]           ...           7 years ago
  • 0.1.1-beta.2 [deprecated]           ...           7 years ago
  • 0.1.1-beta.1 [deprecated]           ...           7 years ago
  • 0.1.1-beta.0 [deprecated]           ...           7 years ago
  • 0.1.0                                ...           7 years ago
  • 0.0.1                                ...           7 years ago
Downloads
Today 0
This Week 0
This Month 91
Last Day 0
Last Week 91
Last Month 0
Dependencies (14)
Dev Dependencies (12)
Dependents (2)

Copyright 2013 - present © cnpmjs.org | Home |