Sha256: 3ab57b1226dbed50946242322995687d2463cae355b81b643eee2607350c4b82
Contents?: true
Size: 764 Bytes
Versions: 2
Compression:
Stored size: 764 Bytes
Contents
module SyntaxHelper def specific_page_vue return " #{controller_name} #{action_name} " end def vue_include_tag(version) javascript_include_tag "https://cdnjs.cloudflare.com/ajax/libs/vue/#{version}/vue.js" if Rails.env.development? end def rails_version "<p>#{Rails.version}</p>".html_safe end def vue_on_rails_version "<p>#{VueOnRails::VERSION}</p>".html_safe end def vue_component(identifier, variable=nil) concat("<div id=\"#{identifier}\" refs=\"#{identifier}\">".html_safe) concat("</div>".html_safe) if(variable != nil) variable.each {|key, value| concat("<div id=\"vueonrails-#{key}\" data-#{key}=\'#{value}\'>".html_safe) concat("</div>".html_safe) }; nil end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
vueonrails-0.2.0 | app/helpers/syntax_helper.rb |
vueonrails-0.1.0 | app/helpers/syntax_helper.rb |