@mahjongg/new-component
New-Component is a basic CLI for creating a new react component.
Last updated 2 years ago by mahjongg .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install @mahjongg/new-component -g
SYNC missed versions from official npm registry.

new-component

New-Component is a basic CLI for creating a new react component.

Install the package globally for best results.

npm install -g @mahjongg/new-component

The component is created with the name specified(Use PascalCase).

ex.

new-component add Footer

A Folder will be created(with the name given) that houses your component(index.js) and a stylesheet(style.css).

Options:

By default, components are created as functional-components.
The -s or --stateful option will create a class-based component.

ex.

new-component add --stateful SignUpForm

Issues:

Please contact me with any issues through github.

Future Dev:

This package is still new and there are plans to add some other features:

  • load in pre-made components like "Modal" or "Form" or "Navbar".
  • add support for Apollo and Redux (add things like store and subscribe to the boilerplate)

Current Tags

  • 0.2.1                                ...           latest (2 years ago)

4 Versions

  • 0.2.1                                ...           2 years ago
  • 0.1.2                                ...           2 years ago
  • 0.1.1                                ...           2 years ago
  • 0.1.0                                ...           2 years ago
Maintainers (1)
Downloads
Today 0
This Week 1
This Month 1
Last Day 0
Last Week 1
Last Month 4
Dependencies (1)
Dev Dependencies (0)
None
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |