I put each of the page CSS at bottom of script tag , like example
<style src="~/assets/css/about.css"></style>
but when i route to another page, if the new page element have the same CSS class with previous page element, it will take the previous page CSS, i know put my CSS in style tag with scoped will prevent this case happen, so any way i can import my CSS in style tag with scoped? I tried
<style scoped>
@import '~/assets/css/about.css';
</style>
but it not working, any one can teach me how to do it :)
Hello
In your page, do you try this ?
<style src="~/assets/css/about.css" scoped>
Have a good day ;)
@jleveugle thanks you so much, and may i ask you one more question ? after i check on
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/style
the style tag with scoped css whether it is not supported on major desktop and mobile browser? :)
Don't be worried, your CSS rules and HTML tag have a uniq data tag. Your CSS rules are prefixed when compiling to impact this template only ;)
You can show the result in your DOM, like this

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Most helpful comment
Hello
In your page, do you try this ?
Have a good day ;)