用额外的间距制作标题标签,并且可以访问子弹
屏幕读取器将读取& nbsp
时,格式化< title>
标签为可以看到的人进行清洁。
<title>contact • company</title>
有什么办法使这一混乱不足吗?
Screen readers will read out things like  
when formatting a <title>
tag to be clean for people that can see.
<title>contact • company</title>
Is there any way to make this less confusing?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我认为在技术上不像您这样的格式在技术上无效。也就是说,我会质疑任何访客的实用性,无论他们是否被看到。
如果您想减少详细的内容,则可以使用Unicode字符,但是请注意,HTML确实会剥离额外的空格,而连续多个空间的唯一方法是使用非断裂空间(
>
> &amp; nbsp;
)字符。至于正确是否正确,Whatwg HTML 5规范指出
&lt; title&gt;
元素的 content模式为“ text” ,但是文本内容模型的定义指出它还包括措辞内容。W3C HTML验证器似乎并未抱怨标题元素中包含的内容。搜索引擎可能以不同的方式处理此操作,有些可能会根据字符或像素宽度的长度截断您的内容。
I don't believe that it's technically invalid to include formatting like you're doing. That said, I'd question the utility of this approach for any visitor regardless of whether they are sighted or not.
If you want to make it less verbose, you could use unicode characters, but be aware that HTML does strip out extra whitespace, and the only way to make more than one consecutive space is to use the non-breaking-space (
) character.
As far as whether it's correct or not, the WHATWG HTML 5 specification states that the
<title>
element's content mode is "Text", however the definition of a Text content model states that it also includes Phrasing content.The W3C HTML validator doesn't seem to complain about phrasing content being included in the title element. Search engines may handle this differently, and some may truncate your content based on length of characters or pixel widths.