plop.js code example
Example: plop.js
module.exports = function (plop) {
plop.setGenerator('components', {
description: 'This will generate the components folder',
prompts: [{
type: 'input',
name: 'name',
message: 'type the name for your components folder'
}],
actions: [{
type: 'add',
path: 'src/components/{{name}}.component.js',
templateFile: 'plop-templates/components.hbs'
}]
});
};