一个简单的例子:
HTML
<p style="color:red!important">
this text is red
<em>
this text is in the initial color (e.g. black)
</em>
this is red again
</p>
Run Code Online (Sandbox Code Playgroud)
CSS
em {
color:initial;
color:unset;
}
Run Code Online (Sandbox Code Playgroud)
initial和之间有什么区别unset?仅支持浏览器