ngxs / schematics

:wrench: Schematics for @ngxs/store

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Schematic should support lint via option --lint-fix

spremi opened this issue · comments

I'm submitting a...

[ ] Regression (a behavior that used to work and stopped working in a new release)
[ ] Bug report  <!-- Please search GitHub for a similar issue or PR before submitting -->
[ ] Performance issue
[x] Feature request
[ ] Documentation issue or request
[ ] Support request => https://github.com/ngxs/store/blob/master/CONTRIBUTING.md
[ ] Other... Please describe:

Current behavior

The option --lint-fix is not accepted by the schematic @ngxs/schematics:store.

Expected behavior

Allow the files generated by schematics to be automatically linted similar to @ng/cli.

Minimal reproduction of the problem with instructions

Run these commands to see difference:

ng g @ngxs/schematics:store --name=test --path=app/store --lint-fix=true
ng g c test --lint-fix=true

ngxs-lint-fix

What is the motivation / use case for changing the behavior?

After generated files are checked in, the linting by IDE (using project configuration) causes additional changes in subsequent commits.

Environment

Libs:
- @angular/core version: 8.2.0
- @ngxs/store version: 3.5.0
 
For Tooling issues:
- Node version: v10.16.0
- Platform: Linux

Others:
Fedora release 29 (5.1.18-200.fc29.x86_64)