Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NameWithSum ¶
NameWithSum returns the filename with its shasum
func NormalizeAssetName ¶
NormalizeAssetName ensures the asset name always start with a "/"
Types ¶
type Asset ¶
type Asset struct { AssetOption Etag string `json:"etag"` NameWithSum string `json:"name_with_sum"` Mime string `json:"mime"` // contains filtered or unexported fields }
Asset holds unzipped read-only file contents and file metadata.
func NewAsset ¶
func NewAsset(opt AssetOption, rawData, brotliData []byte) *Asset
NewAsset creates a new asset
func (*Asset) BrotliReader ¶
BrotliReader returns a bytes.Reader for the compressed content of the asset.
func (*Asset) BrotliSize ¶
BrotliSize returns the size of the compressed version of the asset.
Click to show internal directories.
Click to hide internal directories.