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.
有谁知道如何包含content_tag在助手中?我试过包括ActionView::Helpers::TagHelper.
content_tag
ActionView::Helpers::TagHelper
你应该能够做到这一点:
module ApplicationHelper def something(place, url) content_tag :li do link_to(place, url) end end end
让我知道这是否有效,或者您是否仍有问题。
迈克·莱利