Closed adambrangenberg closed 1 year ago
This makes the plugin unusable in recent Angular CLI versions because of the deprecation of camel case flags (see).
The reason is that the plugin reads the command schematic's schema.json
(f.e. node_modules/@schematics/angular/component/schema.json
for ng generate command
) to figure out the command's flags and their characteristics. However, the command names in the shcema.json
file no longer match the ones in the documentation.
However, I believe that this strategy can still be viable if a couple of tweaks are added. I searched through the Angular CLI repo to try to find where the kebab-case commands are, but couldn't find them, because they just "dasherize" (convert camelCase to kebab-case) the commands found in the schema.json
files (I didn't find where the dasherization happens, but I'm 99% sure it happens somewhere).
That can be part of the possible solution:
schema.json
Thanks! Yea I'll have to look into why angular would have their schema.json not match what the cli is expecting for the generators. Assuming you guys are setup with just plain angular project and not within nx?
I explained this above, but I'll make it clearer: the Angular CLI tool also reads from the schema.json
to parse commands, but I'm almost sure that they dasherize those values in runtime, meaning they'll read inlineTemplate
from schema.json
, buyt only accept inline-template
. And that's why we should use a similar strategy in this plugin.
Yes, I'm on plain Angular.
I also was on plain Angular
hi
I also wanted to let you know about slowly deprecating this plugin in favor for the official on by Nrwl: https://plugins.jetbrains.com/plugin/21060-nx-console
Should I close the issue then?
Current Behaviour
A clear and concise description of what the bug is.
How to Reproduce
Steps to reproduce the behaviour:
Expected Behaviour
To use the new way of adding options, so it won't break in the next Angular version
Screenshots