method

aliased_path_for

rails latest stable - Class: Sprockets::StaticCompiler

Method deprecated or moved

This method is deprecated or moved on the latest stable version. The last existing version (v3.2.13) is shown here.

aliased_path_for(logical_path)
public

No documentation available.

# 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