Sha256: 96d6ad1238e9a14da825e031dae91a158b39789800606c9bd9a3892bfa389f23

Contents?: true

Size: 821 Bytes

Versions: 1

Compression:

Stored size: 821 Bytes

Contents

module Typekit
  module Configuration
    class Default < Base
      private

      def build_map
        context = [ Typekit.address, "v#{ version }", format ]
        Routing::Map.new do
          scope context do
            resources :families, only: :show do
              show ':variant', on: :member
            end

            resources :kits do
              resources :families, only: [ :show, :update, :delete ]
              show :published, on: :member
              update :publish, on: :member
            end

            resources :libraries, only: [ :index, :show ]
          end
        end
      end

      def build_dispatcher
        Connection::Dispatcher.new(adaptor: :standard, token: token)
      end

      def build_processor
        Processor.new(format: format)
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
typekit-client-0.0.2 lib/typekit/configuration/default.rb