- 面包屑导航分隔符应该放在 CSS 中,而不是 HTML 中。只需使用
::after伪元素即可。
nav > ol > li:not(:last-child)::after {
content: " / ";
color: lightgray;
padding: 0 0.5em;
} ::after 伪元素即可。nav > ol > li:not(:last-child)::after {
content: " / ";
color: lightgray;
padding: 0 0.5em;
}