Sha256: ab4bafeabfd4f3e09ae2e8e788a0ccbb4d39deeb14ae8fbafa9007588f59cb4c

Contents?: true

Size: 340 Bytes

Versions: 2

Compression:

Stored size: 340 Bytes

Contents

require 'alephant/renderer/views/base'
require 'json'

module Alephant
  module Renderer
    module Views
      class Json
        include ::Alephant::Renderer::Views::Base

        def setup
          @content_type = 'application/json'
        end

        def render
          ::JSON.generate to_h
        end
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
alephant-renderer-3.2.0 lib/alephant/renderer/views/json.rb
alephant-renderer-3.1.0 lib/alephant/renderer/views/json.rb