1.0.8 • Published 12 months ago
rcli-ent v1.0.8
rcli-ent
react cli to generate boiler plate codes for the components
Usage:
- Install it globally:
npm install -g rcli-ent
/yarn add -g rcli-ent
. - Run the below command in the terminal inside your React.JS project. Syntax: rct -c ComponentName Example: rct -c profile Sample output: Component profile/ProfileComponent.tsx created successfully Component profile/ProfileComponent.scss created successfully
Available options
You can use bellow options to customise.
Attribute | Type | Options | Default Value | Description | Example |
---|---|---|---|---|---|
--skipStyles | boolean | true, false | false | by default component created with style sheet. pass false to override | rct -c profile --skipStyles |
--type | string | functional, class | functional | to generate functional or class component | rct -c profile --type=class |
--styles | string | scss, css | scss | to set style whether to use scss or css | rct -c profile --styles=css |
--camelCase | boolean | true, false | false | to create component with camel casing | rct -c profile --camelCase |
Note: Component path name could be nested folder path to create component in a nested folder.
Example: rct -c src/profile/change-password
Output:
Component src/profile/change-password/ChangePasswordComponent.tsx
created successfully.
Component src/profile/change-password/ChangePasswordComponent.scss
created successfully.
License
MIT Licensed. Copyright (c) Manoj varma 2023.