0.1.2 • Published 5 years ago
@skr571999/crc v0.1.2
Create React Component
A package for creating React component for TS and JS.
Installation
npm i -g @skr571999/crcor running using npx (without Installing)
npx @skr571999/crc -n ComponentNameUsage/Options
Usage: crc -n <name>
Options:
--help Show help [boolean]
--version Show version number [boolean]
-n, --compName Component name [string] [required]
-l, --language Language [js, ts(default)] [string]
-c, --component Make component [No(default)] [boolean]Examples
- For
JavaScript
cd src
crc -n TextBox -l js
# will create following component structure
src
├── components
├── TextBox
├── textbox.view.jsx
└── index.js- For
TypeScript
cd src
crc -n TextBox
# will create following component structure
src
├── components
├── TextBox
├── textbox.view.tsx
└── index.ts- For
TypeScriptwith a.container.tsxfile
cd src
crc -n TextBox -c
# will create following component structure
src
├── components
├── TextBox
├── textbox.container.tsx
├── textbox.view.tsx
└── index.tsSimilar Project
TODO
- Add feature to create (SCSS, model) files
- Add feature to create page Ex. pages/Login