Class Sprockets::StaticAsset
In: lib/sprockets/static_asset.rb
Parent: Asset

`StaticAsset`s are used for files that are served verbatim without any processing or concatenation. These are typical images and other binary files.

Methods

body   fresh?   new   serialized_attributes   to_path   to_s   write_to  

Public Class methods

Define extra attributes to be serialized.

Public Instance methods

Returns file contents as its `body`.

Checks if Asset is fresh by comparing the actual mtime and digest to the inmemory model.

Implemented for Rack SendFile support.

`to_s` is aliased to body since static assets can‘t have any dependencies.

[Validate]