Sha256: fe62afff3152136e30cd94f9137405a7331a87d6b0d305d055e9bd0e4d1b5eb9
Contents?: true
Size: 434 Bytes
Versions: 21
Compression:
Stored size: 434 Bytes
Contents
require "json" module Ohm class Model # Export a JSON representation of the model by encoding `to_hash`. def to_json(*args) to_hash.to_json(*args) end end module Collection # Sugar for to_a.to_json for all types of Sets def to_json(*args) to_a.to_json(*args) end end class List # Sugar for to_a.to_json for lists. def to_json(*args) to_a.to_json(*args) end end end
Version data entries
21 entries across 21 versions & 1 rubygems