Last active
December 11, 2021 23:05
-
-
Save ismailbenhallam/09876692434bb6759fc055e09a722846 to your computer and use it in GitHub Desktop.
Plop config for React app
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module.exports = function (plop) { | |
// component generator | |
plop.setGenerator("component", { | |
description: "React component generator", | |
prompts: [ | |
{ | |
type: "input", | |
name: "name", | |
message: "component name please", | |
}, | |
], | |
actions: [ | |
{ | |
type: "addMany", | |
destination: "src/components/{{pascalCase name}}", | |
templateFiles: "templates/components/*.hbs", | |
base: "templates/components", | |
}, | |
], | |
}); | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment