Sha256: 2e713cb63ce036362efd61f4491f90f5a58c0c65e495e8f2b716846650527b9b
Contents?: true
Size: 441 Bytes
Versions: 6
Compression:
Stored size: 441 Bytes
Contents
module Hippo::Concerns # @see ClassMethods module ApiPath extend ActiveSupport::Concern module ClassMethods def api_path(with_module: false) path = with_module ? to_s : to_s.demodulize path.underscore.dasherize end def from_api_path(path) name = path.underscore.camelize.safe_constantize end end end end
Version data entries
6 entries across 6 versions & 1 rubygems