babel plugin doc gen
A Docs generation
Motivation
Aims to atuo generate json react docs or copy files from files which will parse by babel. All coded with ES6 syntax.
What's inside
- Webpack for all development (server,hotload etc.) and build (package, optimize, etc.) needs.
- Babel for writing codes with ES6 syntax and transpiling them browser compatible codes.
- ESLint for protecting our nice formatted codes.
- Flow for type checking.
- Chai for asserting test errors.
Quick Start
Install and Usage
Go to your project folder
npm install babel-plugin-doc-gen --save
You can import this project in 2 ways.
- Partial import. For ex.
import Transformer from "babel-plugin-doc-gen/lib/api/Transformer";
- All-in-one, minified, optimized single js. For ex. TODO: example coming soon.
Usage
Execute as Babel Plugin
- Use plugin with babel. Add it to babel plugins.
- Execute it with environment.
Configuration File
- create configuration file
.doc.gen.json
in root path. - Configuration file
- hashFile default name is
.hash.json
- if you want to change hash file name then use like following lines
- react : Using generate json react docs.
- copy : Using copy file to another folder
How to contribute
Clone and run npm install
. This will install both run-time project dependencies and developer tools listed
in package.json file.
How to Build for Production
If you need just to build the app (without running a dev server), simply run:
$ npm run build
How to run Unit Tests.
$ npm test