Sha256: 8da025f6cf5d169d3f016f7120e587c2d05d2e55d4455baf15f7bca608825d18

Contents?: true

Size: 1.99 KB

Versions: 31

Compression:

Stored size: 1.99 KB

Contents

module Merb
  module FullTestSlice
    module ApplicationHelper
      
      # @param *segments<Array[#to_s]> Path segments to append.
      #
      # @return <String> 
      #  A path relative to the public directory, with added segments.
      def image_path(*segments)
        public_path_for(:image, *segments)
      end
      
      # @param *segments<Array[#to_s]> Path segments to append.
      #
      # @return <String> 
      #  A path relative to the public directory, with added segments.
      def javascript_path(*segments)
        public_path_for(:javascript, *segments)
      end
      
      # @param *segments<Array[#to_s]> Path segments to append.
      #
      # @return <String> 
      #  A path relative to the public directory, with added segments.
      def stylesheet_path(*segments)
        public_path_for(:stylesheet, *segments)
      end
      
      # Construct a path relative to the public directory
      # 
      # @param <Symbol> The type of component.
      # @param *segments<Array[#to_s]> Path segments to append.
      #
      # @return <String> 
      #  A path relative to the public directory, with added segments.
      def public_path_for(type, *segments)
        ::FullTestSlice.public_path_for(type, *segments)
      end
      
      # Construct an app-level path.
      # 
      # @param <Symbol> The type of component.
      # @param *segments<Array[#to_s]> Path segments to append.
      #
      # @return <String> 
      #  A path within the host application, with added segments.
      def app_path_for(type, *segments)
        ::FullTestSlice.app_path_for(type, *segments)
      end
      
      # Construct a slice-level path.
      # 
      # @param <Symbol> The type of component.
      # @param *segments<Array[#to_s]> Path segments to append.
      #
      # @return <String> 
      #  A path within the slice source (Gem), with added segments.
      def slice_path_for(type, *segments)
        ::FullTestSlice.slice_path_for(type, *segments)
      end
      
    end
  end
end

Version data entries

31 entries across 31 versions & 1 rubygems

Version Path
merb-slices-1.1.3 spec/slices/full-test-slice/app/helpers/application_helper.rb
merb-slices-1.1.2 spec/slices/full-test-slice/app/helpers/application_helper.rb
merb-slices-1.1.1 spec/slices/full-test-slice/app/helpers/application_helper.rb
merb-slices-1.1.0 spec/slices/full-test-slice/app/helpers/application_helper.rb
merb-slices-1.1.0.rc1 spec/slices/full-test-slice/app/helpers/application_helper.rb
merb-slices-1.1.0.pre spec/slices/full-test-slice/app/helpers/application_helper.rb
merb-slices-1.0.15 spec/slices/full-test-slice/app/helpers/application_helper.rb
merb-slices-1.0.14 spec/slices/full-test-slice/app/helpers/application_helper.rb
merb-slices-1.0.13 spec/slices/full-test-slice/app/helpers/application_helper.rb
merb-slices-1.0.12 spec/slices/full-test-slice/app/helpers/application_helper.rb
merb-slices-1.0.1 spec/slices/full-test-slice/app/helpers/application_helper.rb
merb-slices-1.0.10 spec/slices/full-test-slice/app/helpers/application_helper.rb
merb-slices-1.0.11 spec/slices/full-test-slice/app/helpers/application_helper.rb
merb-slices-0.9.9 spec/slices/full-test-slice/app/helpers/application_helper.rb
merb-slices-0.9.8 spec/slices/full-test-slice/app/helpers/application_helper.rb
merb-slices-0.9.12 spec/slices/full-test-slice/app/helpers/application_helper.rb
merb-slices-1.0.2 spec/slices/full-test-slice/app/helpers/application_helper.rb
merb-slices-1.0.3 spec/slices/full-test-slice/app/helpers/application_helper.rb
merb-slices-1.0.4 spec/slices/full-test-slice/app/helpers/application_helper.rb
merb-slices-1.0.5 spec/slices/full-test-slice/app/helpers/application_helper.rb