@disaythis/gen-rtsc
v1.0.10
Published
Component generator for typescript based react aaplication
Downloads
377
Maintainers
Readme
This package is adapted from react-typescript-component-generator for the project's preferred component structure.
Installation
# Install globally
npm install --global @disaythis/gen-rtsc
# Or add it to a project
npm install --save-dev @disaythis/gen-rtscUsage
gen-rtsc <componentName><componentName> can include a directory path.
gen-rtsc ./src/components/ButtoncreatesButtonin the specified directory.gen-rtsc Buttoncreates the component in./Button.
Stateless component styles
gen-rtsc css <componentName> # Generate a stateless component with CSS
gen-rtsc scss <componentName> # Generate a stateless component with SCSS
gen-rtsc <componentName> # SCSS is the defaultDevelopment
npm install
npm test
npm pack --dry-runnpm pack --dry-run lets you review the files that will be included in the npm package without publishing it.
Publishing
Publishing is performed by the GitHub Actions workflow after a GitHub Release is published. Configure npm Trusted Publishing for this repository before creating a release, and increment the version in package.json for every new npm release.
