Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enforce "Import Destructuring Spacing" in tslint #471

Closed
3 tasks done
kirjs opened this issue May 28, 2017 · 6 comments
Closed
3 tasks done

Enforce "Import Destructuring Spacing" in tslint #471

kirjs opened this issue May 28, 2017 · 6 comments
Assignees

Comments

@kirjs
Copy link
Collaborator

kirjs commented May 28, 2017

Motivation

Right now there is no consistent way to handle spaces in destructured imports, this introduces some noise in commits as right now we have no spaces, but angular CLI as well as some formatters actually add spaces.

Also ts-lint only validates the case with spaces

Solution

  • Add spaces across the codebase
  • Add TS-lint rule
  • Document the configuration for the websorm and VSCode

Editor configuration

Intellij/Webstorm
Settings -> Code Style -> TypeScript -> Spaces Tab -> Check “ES6 import/export braces”

see also
mgechev/codelyzer#40
https://stackoverflow.com/questions/41447602/tslint-remove-missing-whitespace-rule-on-import

kirjs added a commit that referenced this issue May 28, 2017
@tessaSAC
Copy link
Collaborator

@RingoKam you can do third checkbox VSC part lol 😬

@tessaSAC
Copy link
Collaborator

tessaSAC commented Jun 3, 2017

@kirjs You did the first task right?

@kirjs
Copy link
Collaborator Author

kirjs commented Jun 3, 2017

I did

@kirjs
Copy link
Collaborator Author

kirjs commented Jun 3, 2017

Assigning to ringo kam for an advice on how this could be done with VS Code

@kirjs
Copy link
Collaborator Author

kirjs commented Jun 10, 2017

Added to contributing md, assume vs code does that

@RingoKam
Copy link
Contributor

RingoKam commented Jul 2, 2017

Oh didn't see this until now lol

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants