Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有一个这样的页面:
页面 http://ompldr.org/vZTJtdw
我需要用“>”字符对齐线条。我认为这可以使用表格来完成,但我想有更好的解决方案吗?
到目前为止我所拥有的:https ://gist.github.com/2864265
添加
.title { display: inline-block; width: 2.8em;}
或者使用更灵活(无需猜测宽度)、更健壮(即使在 CSS 关闭或不支持派对时也能工作)、更合乎逻辑(您拥有的是二维数据数组)的表格)。
我认为对齐意味着您希望将 GREATER THAN 符号垂直放在同一行上。
使用一张桌子。将左列向右对齐,使其与最右边的字符对齐。