1.0.25 • Published 4 years ago

react-doc-tab v1.0.25

Weekly downloads
3
License
MIT
Repository
github
Last release
4 years ago

React DocTab 📑

npm version build status oclif prettier

Generate React component as Live Demo & Code Example

npm.io

Maintaining example code and live demo separately makes it painful, it's easy to get them out of sync 🙅

Code can't lie, example code can 💥

DocTab keeps your example code up to date with live demo 💪

Install

npm install -D react-doc-tab react-doc-tab-template

Demo

DocTab live demo

Usage

To use DocTab in your project:

  • default export component
  • name file as [filename].doctab.[ext]
  • run $ npx doctab generate

Import generated DocTab components. 🎉

Generated DocTab Files

  • By default generated files will be prefixed with _ for example:
    MyComponent.doctab.jsx & MyComponent.doctab.css -> _MyComponent.jsx
  • You can set custom prefix with --prefix flag:
    $ doctab generate --prefix=CustomPrefix

Built with DocTab

License

MIT