emmetio / emmet

The essential toolkit for web-developers
http://emmet.io
MIT License
4.45k stars 518 forks source link

Feature Request: Support for Angular Bindings and Directives #618

Open LuksTrackmaniaCorner opened 3 years ago

LuksTrackmaniaCorner commented 3 years ago

I've been using emmet with the Angular Framework in VS Code recently, and noticed that the emmet does not allow to generate the following abbreviations, because the attribute syntax is too limited. These examples should showcase all the problems:

  1. Event Binding: btn[(click)="DoSomething()"] should expand to <button (click)="DoSomething()"></button>

  2. Attribute Binding: div[[style.width]=100px] should expand to: <div [style.width]="100px"></div>

  3. Two-way Binding: input[[(ngModel)]=username] should expand to <input [(ngModel)]="username">

  4. Structural Directive: ng-template[*ngIf=show] should expand to <ng-template *ngIf="show"></ng-template>

Issues:

I tried escaping with \, but I couldn't get any of the shown examples to work.

It would be really helpful for me if these issues could be fixed

Phantoll commented 2 years ago

+1 some solution to escaping special chars would be gread.