我有这个代码:
%p
A debtor with the court's approval can hire attorneys via
%a{:id=>"proc",:href=>'/codes#rule327'}Section 327.
Run Code Online (Sandbox Code Playgroud)
这呈现:
经法院批准的债务人可以通过第327条聘请律师.
我知道这是非常挑剔的,但我不希望这个时期加粗.当我尝试:
%p
A debtor with the court's approval can hire attorneys via
%a{:id=>"proc",:href=>'/codes#rule327'}Section 327
\.
Run Code Online (Sandbox Code Playgroud)
它产生:
经法院批准的债务人可以通过第327条聘请律师.
我想知道如何获得:
经法院批准的债务人可以通过第327条聘请律师.
may*_*ron 35
HAML具有专门设计的辅助方法,以"以比空白移除方法允许的更精确的方式操纵空白".
有三种方法:环绕,前置和成功,它们提供更好的空白控制.在您的情况下,您可以使用这样的成功助手来附加链接后的句点:
%p
A debtor with the court's approval can hire attorneys via
= succeed "." do
%a{:id=>"proc",:href=>'/codes#rule327'}Section 327
Run Code Online (Sandbox Code Playgroud)
请参阅"帮助程序方法"下的HAML文档.
ual*_*ker 13
您可以在标记定义后使用外部"space eater"(>):
%p
A debtor with the court's approval can hire attorneys via
%a{:id=>"proc",:href=>'/codes#rule327'}>Section 327
.
Run Code Online (Sandbox Code Playgroud)