Preserve Angular control flow syntax in ngNonBindable directive (#20066)
Co-authored-by: fisker <lionkay@gmail.com>
This commit is contained in:
1 parent
1a15312010
commit
0292df6bf3
6 files changed
+240
-2
No files matched your search
@@ -0,0 +1,20 @@
|
||||
#### Preserve Angular syntax inside elements with `ngNonBindable` directive (#20066 by @splincode)
|
||||
|
||||
<!-- prettier-ignore -->
|
||||
```html
|
||||
<!-- Input -->
|
||||
<span ngNonBindable>@if(foo){bar}</span>
|
||||
<span ngNonBindable>@let foo=bar+baz;</span>
|
||||
|
||||
<!-- Prettier stable -->
|
||||
<span ngNonBindable>
|
||||
@if (foo) {
|
||||
bar
|
||||
}
|
||||
</span>
|
||||
<span ngNonBindable>@let foo = bar + baz;</span>
|
||||
|
||||
<!-- Prettier main -->
|
||||
<span ngNonBindable>@if(foo){bar}</span>
|
||||
<span ngNonBindable>@let foo=bar+baz;</span>
|
||||
```
|
||||
Reference in new issue
Block a user