我会让代码说话。我什至尝试将 important!
添加到 css 值,但仍然无法删除行。
在 Chrome 和 Safari 中测试。
.no-decoration {
text-decoration: none;
}
<h1> ins tag</h1>
<ins>
<a class="no-decoration" href="">Some link</a>
</ins>
<h1>no ins tag</h1>
<div>
<a class="no-decoration" href="">Some link</a>
</div>
最佳答案
您应该为 <ins>
添加样式标记也。
使用以下代码更新您的 CSS,
.no-decoration, ins {
text-decoration: none;
}
关于html - 为什么文字装饰: none is not working inside HTML <ins> element,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/50576259/