Coder Social home page Coder Social logo

fast-react-docgen's Introduction

Inspired by React ToolBox and React StyleGuide Generator comes the next generation of component sandboxing and collaboration. Currently targeted at TXL_components

Installation

Installing the project through npm, creates a txl-docs cli. Otherwise commands can be executed through ./bin/cli.js

npm install txl-docs -D

CLI

usage

txl-docs [start|generate:dll|deploy] [options]

start [options] runs server at localhost:[port] for txl docs

Option Description Default
--demo-ext [ext] Specify demo file extension .demo.jsx
-p, --port [port] Specify port: [port] 8080
-l, --log-level Specify log level: [level], (debug, info, warn, error, off) info

generate:dll creates a vendor dll, and is used to force the docs to recreate a dll. This dll should update automatically on start if the package.json has changed since the last run. But if you need to force the update or if the vendor.dll becomes broken run this command.

deploy [options] builds the productions version of the docs, and uploads them to S3.

Option Description Default
-b, --s3-Bucket the name of the current s3 bucket for the docs txl.tune.com
-r, --region the region of the bucket us-west-2
--demo-ext [ext] Specify demo file extension .demo.jsx
-B, --no-build Skip the build step. false
-U, --no-upload Skip the upload step. false
-i, --key-id [id] The Aws access key process.env.AWS_ACCESS_KEY_ID
-s, --secret-key [id] The Aws secret access key id process.env.AWS_SECRET_ACCESS_KEY

Aws credentials can also be configured through your ~/.aws/credentials file.

Documenting components

To create a component demo, create a file [component].demo.jsx. Then from that demo file export a valid react component and that will be the rendered demo. Make sure to create a demo file for each component in the demo, for example if both a

Note: In the legacy demos, a global return is used instead of export default.

fast-react-docgen's People

Contributors

alexjuarez avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.