add-component
Advanced tools
Comparing version 2.2.0 to 2.3.0
@@ -26,3 +26,4 @@ #!/usr/bin/env node | ||
.option('-r, --redux', 'Create Redux Store') | ||
.option('-s, --style', `Add ${componentName}.css`) | ||
.option('-c, --css', `Add ${componentName}.css`) | ||
.option('-d, --directory <directory>', 'Use directory') | ||
.parse(process.argv) | ||
@@ -33,3 +34,3 @@ | ||
function createComponent (name) { | ||
const rootDirectory = path.resolve(name) | ||
const rootDirectory = program.directory ? path.join(path.resolve(program.directory), name) : path.resolve(name) | ||
const hasCSS = program.css | ||
@@ -36,0 +37,0 @@ const makeFn = program.fn |
{ | ||
"name": "add-component", | ||
"version": "2.2.0", | ||
"version": "2.3.0", | ||
"description": "Create React Component CLI", | ||
@@ -5,0 +5,0 @@ "repository": { |
@@ -130,5 +130,12 @@ # add-component | ||
## Additional options | ||
``` | ||
# Define directory with components | ||
$ add-react-component -d src Example | ||
``` | ||
## License | ||
MIT © [Jack Hanford](http://jackhanford.com) |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
9196
23
194
141