0.2.0 • Published 9 years ago
rgen v0.2.0
rgen
React component generator
Installation
Using npm
npm install -g rgenUsing yarn
yarn global add rgenUsage
rgen -n MyNewComponent -e jsx -w story -t stateless
Options
-n | --name <name-of-component>- the name for the component / file to generate, by default the component name will be a directory that an index.js(x) file gets written to.-e | --ext <file-extension-for-component>- jsx - (default)
- js
-d | --dir- output directory-t | --type <component-type>- type of component to create- stateless - (default) functional stateless component
- stateful
-w | --with <space-separated-options>- generate additional files, currently supports- story - Storybook for react story
- scss (soon)
TODO
- Classes / functional components
- Stories (storybook)
- (S)CSS
- Configure output folder (Each option can have a separate folder, default to class folder)
- Styled component
- Jest / enzyme
- Snapshots
- Read .rgen file for configs (optional)
0.2.0
9 years ago