Skip to content
/ crf Public

A CLI tool to create React component boilerplate

License

Notifications You must be signed in to change notification settings

13sfaith/crf

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Contributors Forks Stargazers Issues MIT License LinkedIn


CRF

A Simple React Component Creator
Explore the docs »

Report Bug · Request Feature

Table of Contents

About The Project

Built With

Getting Started

To get a local copy up and running follow these simple steps.

Prerequisites

To build your own verison of this script you will need.

  • Cargo
  • Rust
# if you use rustup update rust using:
rustup update

Installation

  1. Clone the repo
git clone https://github.com/13sfaith/crf.git
  1. Build the release
cargo build --release
  1. The executable is then stored in:
./crf/target/release

Usage

Create a react component either class or function (default class)

USAGE: crf [OPTIONS]

FLAGS: -h, --help Prints help information -V, --version Prints version information

OPTIONS: -t, --type Type of component (-t c or -t f) [default: c]

ARGS: Name of component

An example use case would be:

example image

This would create a js file named "Example.js" in the current working directory The file would contain a boilerplate class file that would look like:

example class

The default behavior of the tool is to create a class, however if you would like to make a functional component we've got you covered.

Simply use the function tag as such:

example imag

This will create a js file named "Example.js" with the following boilerplate:

example function

Happy Hacking!

Roadmap

See the open issues for a list of proposed features (and known issues).

Contributing

Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

License

Distributed under the MIT License. See LICENSE for more information.

Contact

Spencer Faith - @13sfaith - [email protected]

Project Link: https://github.com/13sfaith/crf

Acknowledgements

About

A CLI tool to create React component boilerplate

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages