So, I want to pass a template to the component and render this template inside with style applied from this component, not from the calling component. Is it any way to do this without setting ViewEncapsulation.None?
I made a small stackblitz for that. I want param button also rendered green.
https://stackblitz.com/edit/angular-zrpufe?file=src%2Fapp%2Fhello.component.ts
Just try this one
EDIT: This deep selector has been deprecated for a long time and CSS Work Group has not agreed on an alternative yet. Untill there is a replacement I favor to use deep, because, while alternative solutions like wrapping the element with a div and styling globally is good to go, it has problems too, the biggest issue with it, it doesnt work inter-modules in angular. It is up to you to decide.