fix($compile): properly denormalize templates when only one of the start/end symbols is different #13848
Conversation
…art/end symbols is different Previously, if either of the start/end interpolation symbols remained unchanged (i.e. `{{` or `}}`), then directive templates would not be denormalized properly. Changing only one of the start/end symbols (but not both) is an uncommon but legitimate usecase.
51ae443
to
66fd200
Compare
@@ -3137,6 +3137,54 @@ describe('$compile', function() { | |||
}); | |||
|
|||
|
|||
it('should support custom start interpolation symbol, even when `endSymbol` doesn\'t change', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
endSymbol is the default
? (and below)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What @gkalpak means is that these test that the functionality works even if you change only one of startSymbol
and endSymbol
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I know, I just thought it was more explicit to state that the other symbol remains the default symbol. As is works for me though.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I meant to change it as @Narretz suggested upon merge, but forgot to amend the commit before pushing 😞
LGTM with a small style suggestion |
LGTM |
…art/end symbols is different Previously, if either of the start/end interpolation symbols remained unchanged (i.e. `{{` or `}}`), then directive templates would not be denormalized properly. Changing only one of the start/end symbols (but not both) is an uncommon but legitimate usecase. Closes #13848
Backported to |
Previously, if either of the start/end interpolation symbols remained unchanged (i.e.
{{
or}}
), then directive templates would not be denormalized properly. Changing only one of the start/end symbols (but not both) is an uncommon but legitimate usecase.