我在我的haml文件中有以下幾行代碼。如何在haml中添加空格
(Requested:
%strong<>
= comment.commentable.requested_check_in.present? ? comment.commentable.requested_check_in.strftime("%m/%d/%Y") : ""
="-"
= comment.commentable.requested_check_out.present? ? comment.commentable.requested_check_out.strftime("%m/%d/%Y") : ""
, Actual:
%strong<>
= comment.commentable.actual_check_in.present? ? comment.commentable.actual_check_in.strftime("%m/%d/%Y") : ""
="-"
= comment.commentable.actual_check_out.present? ? comment.commentable.actual_check_out.strftime("%m/%d/%Y") : ""
).
我想是,要
(Requested: " "
後有一個白色的空間,但該行沒有工作。
生成的HTML如何以及您的預期結果是什麼? – Stefan