Transclusion : apply style to ng-content

Viewed 250

I am facing an issue regarding how to style trasncluded content.

When reading through the documentation, it is said that there are custom selectors that can do the job. And they do ! But it is also said

The shadow-piercing descendant combinator is deprecated and support is being removed from major browsers and tools. As such we plan to drop support in Angular (for all 3 of /deep/, >>> and ::ng-deep). Until then ::ng-deep should be preferred for a broader compatibility with the tools.

This means that, because it is deprecated, those selectors should not be used.

As I am facing this issue right now, I would like to know the alternative provided to style the transcluded content.

I have asked on an old question but it doesn't seem to work for non-shadow DOM encapsulation.

Here is a stackblitz with a very minimal reproduction of the issue.

0 Answers
Related