Sha256: 85f2b15717469465a5f495fc3b9efc654078dd621d6a600d64a0153a041b91cd
Contents?: true
Size: 493 Bytes
Versions: 10
Compression:
Stored size: 493 Bytes
Contents
require 'pathname' require 'dry/core/inflector' require 'rom/types' require 'rom/setup/auto_registration_strategies/base' module ROM module AutoRegistrationStrategies class NoNamespace < Base option :directory, reader: true, type: PathnameType option :entity, reader: true, type: Types::Strict::Symbol def call Dry::Core::Inflector.camelize( file.sub(/^#{directory}\/#{entity}\//, '').sub(EXTENSION_REGEX, '') ) end end end end
Version data entries
10 entries across 10 versions & 1 rubygems