-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Object literals in Angular templates are missing trailing commas #15897
Labels
lang:angular
Issues affecting Angular template (not general JS/TS issues used for Angular)
status:needs discussion
Issues needing discussion and a decision to be made before action can be taken
Comments
mmeylan
changed the title
Object in Angular templates are missing trailing commas on the last line
Object literals in Angular templates are missing trailing commas
Jan 9, 2024
It's indented to not support
But maybe it's supportted now? |
fisker
added
lang:angular
Issues affecting Angular template (not general JS/TS issues used for Angular)
status:needs investigation
Issues that need additional investigation, e.g. to understand whether the reported behavior is a bug
labels
Jan 15, 2024
Ah, supported since May, 2023. angular/angular#49535 |
fisker
added
status:needs discussion
Issues needing discussion and a decision to be made before action can be taken
and removed
status:needs investigation
Issues that need additional investigation, e.g. to understand whether the reported behavior is a bug
labels
Jan 15, 2024
It seems still not supported in call arguments. Prettier 3.2.2 --parser angular
--print-width 120 Input: <div
*ngIf="call( a)"
>
</div> Output: <div *ngIf="call(a)"></div> Prettier 3.2.2 --parser angular
--print-width 120 Input: <div
*ngIf="call( a,)"
>
</div> Output: SyntaxError: Unexpected token ) |
4 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
lang:angular
Issues affecting Angular template (not general JS/TS issues used for Angular)
status:needs discussion
Issues needing discussion and a decision to be made before action can be taken
Prettier 3.1.1
Playground link
Input:
Output:
Expected behavior:
Trailing commas should be kept/inserted in object literals. This used to work on 2.8.
The text was updated successfully, but these errors were encountered: