Ad
Is It Possible To Generate Multiple Angular Components Using Single Angular-cli Command Like Ng Generate Component Comp1, Comp2, Comp3?
I need to create ten Angular components like comp1, comp2, comp3, comp4, ..., comp10. So I need to execute same command for ten times for each component like ng g c comp1, ng g c comp2, etc.
Is there any option to generate multiple angular components using single angular-cli command like ng g c comp1, comp2, comp3.
Ad
Answer
Well, there is nothing as of now by Angular CLI to create multiple components. But this can be done trivially in any shell.
Run this command into your bash shell -
for i in comp1 comp2; do ng g c "${i}"; done
Special thanks to Ingo Bürk's answer
Ad
source: stackoverflow.com
Related Questions
- → Make a Laravel collection into angular array (octobercms)
- → Laravel {!! Form::open() !!} doesn't work within AngularJS
- → Angularjs not working inside laravel form
- → Analysis of Flux implementations
- → how to write react component to construct HTML DOM
- → angular ng-repeat and images in a row
- → Conditional BG Color on AngularJS
- → Should I 'use strict' for every single javascript function I write?
- → getting the correct record in Angular with a json feed and passed data
- → "Undefined is not a function" at .toBe fucntion
- → angularjs data binding issue
- → Angular / JavaScript auto hydrate an instance
- → Convert generic text string in json object into valid url using Angular
Ad