creating alias to javascript_script_tag
This commit is contained in:
parent
9e7eea0fc2
commit
910e8fd314
@ -23,15 +23,13 @@ module Sinatra
|
|||||||
list.collect { |source| stylesheet_tag(source, options) }.join("\n")
|
list.collect { |source| stylesheet_tag(source, options) }.join("\n")
|
||||||
end
|
end
|
||||||
|
|
||||||
def javascript_include_tag(*sources)
|
|
||||||
javascript_script_tag *sources
|
|
||||||
end
|
|
||||||
|
|
||||||
def javascript_script_tag(*sources)
|
def javascript_script_tag(*sources)
|
||||||
list, options = extract_options(sources)
|
list, options = extract_options(sources)
|
||||||
list.collect { |source| javascript_tag(source, options) }.join("\n")
|
list.collect { |source| javascript_tag(source, options) }.join("\n")
|
||||||
end
|
end
|
||||||
|
|
||||||
|
alias :javascript_include_tag, :javascript_script_tag
|
||||||
|
|
||||||
def link_to(desc, url, options = {})
|
def link_to(desc, url, options = {})
|
||||||
tag("a", options.merge(:href => url_for(url))) do
|
tag("a", options.merge(:href => url_for(url))) do
|
||||||
desc
|
desc
|
||||||
|
Loading…
Reference in New Issue
Block a user