add extra_attributes option that adds extra attributes to links. #228

Closed
wants to merge 1 commit into
from
Jump to file or symbol
Failed to load files and symbols.
+1 −0
Diff settings

Always

Just for now

@@ -93,6 +93,7 @@ def link(text, target, attributes = {})
target = url(target)
end
attributes[:href] = target
+ attributes = @options[:extra_attributes].merge(attributes) if @options[:extra_attributes]
tag(:a, text, attributes)
end