Sha256: 6b0e78944a1133f5c89149182d45b907777e136511f49ef5001b96d6df1dce2d
Contents?: true
Size: 464 Bytes
Versions: 17
Compression:
Stored size: 464 Bytes
Contents
module JSONAPIonify::Api module Resource::Definitions::Contexts def self.extended(klass) klass.class_eval do extend JSONAPIonify::InheritedAttributes inherited_hash_attribute :context_definitions end end def context(name, **opts, &block) self.context_definitions[name.to_sym] = Context.new( **opts, existing_context: self.context_definitions[name.to_sym], &block ) end end end
Version data entries
17 entries across 17 versions & 1 rubygems