在我的Rails应用程序中,我想将nofollow, noindex
添加到几个链接中。但是,我不确定是否需要添加comma(,)
。
哪一个是正确的?
1. <%= link_to 'Apply', apply_new_path, rel: 'nofollow, noindex' %> # with comma(,)
or
2. <%= link_to 'Apply', apply_new_path, rel: 'nofollow noindex' %> # no comma(,) used here
a和area元素上的rel属性控制元素创建的链接类型。属性的值必须是一组无序的、以空格分隔的唯一标记。
- WHATWG-HTML生活水平:链接