You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
alpha.39: classes added to the original element removed by host class property #4583
@tbosch I would be surprised if the new behaviour would be a correct one. I remember that we used to have logic in the compiler where classes set by host were merged with ones already present on a host element. IMO it made sense.
What would be rationale for changing this merging behaviour?
My initial thought was that treating class here as a special case seems wrong / not intuitive to users. However, other alternatives seem not right either: E.g. using:
host: { 'class.my-class': true
would clearly show that this is a special case, however, no one would use false as value...
So I am adding the previous behavior back. I.e. host attribtues class and style get merged with the attributes on the element.
Activity
naomiblack commentedon Oct 9, 2015
This is important but not blocking. @adamdbradley says they have another way around this.
mhevery commentedon Oct 10, 2015
@adamdbradley and @tbosch discussed this today. I believe that @tbosch said that this is the correct behavior. @tbosch can you verify?
pkozlowski-opensource commentedon Oct 10, 2015
@tbosch I would be surprised if the new behaviour would be a correct one. I remember that we used to have logic in the compiler where classes set by host were merged with ones already present on a host element. IMO it made sense.
What would be rationale for changing this merging behaviour?
tbosch commentedon Oct 10, 2015
My initial thought was that treating
classhere as a special case seems wrong / not intuitive to users. However, other alternatives seem not right either: E.g. using:would clearly show that this is a special case, however, no one would use
falseas value...So I am adding the previous behavior back. I.e. host attribtues
classandstyleget merged with the attributes on the element.fix(compiler): merge `class` and `style` attributes from the element …
angular-automatic-lock-bot commentedon Sep 7, 2019
This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.
Read more about our automatic conversation locking policy.
This action has been performed automatically by a bot.