-
Notifications
You must be signed in to change notification settings - Fork 424
Closed
Description
Description
When having multiple templates with different css and switching between them, the latest one to apply is the one that ends up winning. Switching back to the first template keeps the css of the previous one.
Steps to Reproduce
- Generate a new project with
$ npm init lwr
$ npm install
$ npm run start
- Create a component with two templates, as described on the docs
- Add the respective route to lwr.config.json
- Enter the component and switch templates
Expected Results
Css is scoped to the respective html template
Actual Results
Css from different template is being applied
Browsers Affected
Chrome 100.0, Safari 15.4, Firefox 98.0.2
Version
- LWC: 2.5.8
- LWR: 0.6.4
Additional context/Screenshots
This happens if you select either Typescript or Javascript project template
It also happens when using the Recipes App
The only place where I couldn't reproduce the issue is on webcomponent.dev
Metadata
Metadata
Assignees
Labels
No labels