Linux Ubuntu 16.10
1.0.0-beta.32.3
by running ng new project default configuration for semicolon is :
"semicolon": ["always"]
in visual studio code changing it to "semicolon": ["never"] does not work but "semicolon": [true, "never"] works correctly (i did not test it in other code editors)
also there is no option in ng new for none semicolon style
TSLint customization is at the discretion of the user after project creation. There are far too many rules to offer command options-based customization. The tslint fix option should allow you to update your code (within reason) after the rules are changed.
Closing as answered by @clydin.
I faced with updating cli and my project. Updating process is hard, because I don't use semicolons, but cli does. I have generated a new project in a separate folder via [email protected] (as you said in update guid) and have run simple diff cmd:
diff -bur Project/ Project-newcli/
Output was very large. Option for disabling semicolons can be useful for this case.
Maybe we can reopen it? Or reopen and delegate to community?
you can use ng lint to remove the semicolons if desired.
1) ng new <projectname> / cd <projectname>
2) edit the semicolon rule in tslint.json to the following:
"semicolon": [
true,
"never"
],
3) ng lint --fix
@clydin
Thank you for workaround!
I think it's not so hard to transform these steps to code and merge that into cli. Why not?
There's a virtual cornucopia of tslint options that could be adjusted. I think with the ease of the above mentioned steps some documentation would be far more effective and a much lower maintenance burden for the CLI. Not to mention future-proof; if, for example, new tslint style rules were to be added.
@clydin
I get it, thank you. +1 for more docs about common ng lint --fix use cases.
This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.
Read more about our automatic conversation locking policy.
_This action has been performed automatically by a bot._
Most helpful comment
you can use
ng lintto remove the semicolons if desired.1)
ng new <projectname>/cd <projectname>2) edit the semicolon rule in
tslint.jsonto the following:3)
ng lint --fix