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
ng new --viewEncapsulation Native|None|ShadowDom do nothing #13689
Hi,
I try to start new project with default viewEncapsulation set to ShadowDom.
According to ng new documentation, i use --viewEncapsulation flag.
But once the project is generated and served, app-root does not have #shadow-root.
I tried all the other encapsulation but I do not see any result.
What is the expected result for this flag?
Set default shematic with "viewEncapsulation": "ShadowDom" in angular.json and generate app.component.ts with encapsulation: ViewEncapsulation.ShadowDom OR
Add to main.ts :
ng new view-test --skip-git --skip-install --viewEncapsulation ShadowDom
or
ng new view-test --skipGit --skipInstall --view-encapsulation Native
or
ng new view-test --skipGit --skipInstall --viewEncapsulation None
Activity
alan-agius4 commentedon Feb 16, 2019
Hi, thanks for reporting this. The problem seems to be that
encapsulationIs not being set in the component.kekel87 commentedon Feb 17, 2019
What is the reason of this choice ? Why we don't set option globally in main.ts ?
fix(@schematics/angular): fixes issue that `ViewEncapsulation` is not…
fix(@schematics/angular): fixes issue that `ViewEncapsulation` is not…
angular-automatic-lock-bot commentedon Sep 9, 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.
fix(@schematics/angular): fixes issue that `ViewEncapsulation` is not…