Skip to content

Latest commit

 

History

History
37 lines (24 loc) · 946 Bytes

README.md

File metadata and controls

37 lines (24 loc) · 946 Bytes

This package automates the generation of React/RN Components in typescript.


Using the command line, and assuming we're creating a component ArticleTitle, you will be able

to generate the following files:

1- index.tsx
2- ArticleTitle.tsx
3- a style file: You can choose one of the following options:
'CSS'| 'SCSS'| 'Less'| 'Sass'| 'React Native Style'| 'Styled Components'.
4- an optional test file: ArticleTitle.test.tsx

INSTALLATION:

yarn add @tareqdayya/react-ts-files-generator --dev

  or

npm i @tareqdayya/react-ts-files-generator --save-dev


HOW TO USE:

on the command line:

yarn gencomp

  or

npm gencomp

You will get asked a few questions, answer them.
Boilerplate code generated :)

  • If the path to the files doesn't exist, worry not––the package will create the directories for you.