Sha256: c601a5f4d949632bd4d524495c89af61d325ea3a4e3b89025fd06cf1718c08b2
Contents?: true
Size: 660 Bytes
Versions: 6
Compression:
Stored size: 660 Bytes
Contents
require 'uv' module BrighterPlanetHelper def render_or_nothing(*args) begin render(*args) rescue ::ActionView::MissingTemplate nil end end def syntax(code, lang = 'ruby') ::Uv.parse(code, 'xhtml', lang, false, :idle).html_safe end def link_to_homesite(text, path = '') if ::BrighterPlanetLayout.application_name == 'Brighter Planet' path.insert 0, '/' else path.insert 0, 'http://brighterplanet.com/' end link_to text, path end def brighter_planet_layout_cdn_url(path) [ request.protocol, ::BrighterPlanetLayout::CDN, "/#{::BrighterPlanetLayout::VERSION}", path ].join end end
Version data entries
6 entries across 6 versions & 2 rubygems