Sha256: 82306b396cbb671053376e9007de9868369be78106b5cdc2a14b44836adf249b
Contents?: true
Size: 318 Bytes
Versions: 5
Compression:
Stored size: 318 Bytes
Contents
require 'rabl' module Gon module Rabl class << self def parse_rabl(rabl_path, controller) source = File.read(rabl_path) rabl_engine = ::Rabl::Engine.new(source, :format => 'json') output = rabl_engine.render(controller, {}) JSON.parse(output) end end end end
Version data entries
5 entries across 5 versions & 1 rubygems
Version | Path |
---|---|
gon-2.3.0 | lib/gon/rabl.rb |
gon-2.2.2 | lib/gon/rabl.rb |
gon-2.2.0 | lib/gon/rabl.rb |
gon-2.1.2 | lib/gon/rabl.rb |
gon-2.1.0 | lib/gon/rabl.rb |