instance method aliased_path_for

Ruby on Rails 3.2.22.5

Since v3.2.22.5 Last seen in v3.2.22.5

Signature

aliased_path_for(logical_path)

No documentation comment.

Parameters

logical_path req
Source
# File actionpack/lib/sprockets/static_compiler.rb, line 48
    def aliased_path_for(logical_path)
      if File.basename(logical_path).start_with?('index')
        logical_path.sub(/\/index([^\/]+)$/, '\1')
      else
        logical_path.sub(/\.([^\/]+)$/, '/index.\1')
      end
    end

Defined in actionpack/lib/sprockets/static_compiler.rb line 48 · View on GitHub · Improve this page · Find usages on GitHub

Defined in Sprockets::StaticCompiler

Type at least 2 characters to search.

↑↓ navigate · open · esc close