/* SCAFFOLDING SCRIPT */ const componentName = process.argv[2]; const layerName = process.argv[3]; const moduleName = process.argv[4]; if (!componentName || !layerName || !moduleName) { throw 'One of the following arguments was not passed. Usage: jss scaffold '; } if (!/^[A-Z][A-Za-z]+$/.test(componentName)) { throw 'Component name should start with an uppercase letter and contain only letters.'; } if (!/[A-Za-z]+$/.test(layerName)) { throw 'Layer name should start with an uppercase letter and contain only letters.'; } if (!/[A-Za-z]+$/.test(moduleName)) { throw 'Module name should start with an uppercase letter and contain only letters.'; } const componentRootPath = `src/${layerName}/${moduleName}/components`; //...