Sha256: 5752a6a8137f1fc2f335b6c2cb0f2a4335a288872f9f2cd0968dffd55a6cf13f

Contents?: true

Size: 588 Bytes

Versions: 6

Compression:

Stored size: 588 Bytes

Contents

# frozen_string_literal: true

module ApipieDSL
  module Routing
    module MapperExtensions
      def apipie_dsl(options = {})
        namespace 'apipie_dsl', path: ApipieDSL.configuration.doc_base_url do
          constraints(version: /[^\/]+/, section: /[^\/]+/, class: /[^\/]+/,
                      method: /[^\/]+/) do
            get(options.reverse_merge("(:version)/(:section)/(:class)/(:method)" => 'apipie_dsls#index', as: :apipie_dsl))
          end
        end
      end
    end
  end
end

ActionDispatch::Routing::Mapper.send :include, ApipieDSL::Routing::MapperExtensions

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
apipie-dsl-2.6.2 lib/apipie_dsl/routing.rb
apipie-dsl-2.6.1 lib/apipie_dsl/routing.rb
apipie-dsl-2.6.0 lib/apipie_dsl/routing.rb
apipie-dsl-2.5.0 lib/apipie_dsl/routing.rb
apipie-dsl-2.4.0 lib/apipie_dsl/routing.rb
apipie-dsl-2.3.0 lib/apipie_dsl/routing.rb