Search code examples
ionic4

Ionic 4 CLI config generate for inline template and style


someone knows how to configure ionic to generate components with inline template and style. For example in Angular this is "ng g c foo -t -s" and on Ionic?. But the idea is configure it in angular.json for default

Regards


Solution

  • your idea were in a right way.
    Just remove "defaultCollection" in angular.json and you will be okay

    "cli": {
      "defaultCollection": "@ionic/angular-toolkit"
    }
    

    It may break build processes, but you always can return it back. And it is know issue (https://github.com/ionic-team/angular-toolkit/issues/446) that this toolkit does not support inline template/styles