decoding

package
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 25, 2026 License: MIT Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// Sync Decode image synchronously for immediate presentation. Blocks other tasks until
	// image is processed. Best for critical above-the-fold images that must appear instantly.
	Sync = Decoding("sync")

	// Async Decode image asynchronously to avoid blocking other tasks. Allows page interaction
	// while image processes in background. Good for non-critical images.
	Async = Decoding("async")

	// Auto Let browser decide optimal decoding strategy based on image importance and context.
	// Default behavior that balances performance with user experience automatically.
	Auto = Decoding("auto")
)

Variables for Decoding values

Functions

This section is empty.

Types

type Decoding

type Decoding []byte

Decoding Image decoding priority hint for browser optimization. Controls when images are processed and painted to balance performance with user experience and page responsiveness.

func Custom

func Custom(value string) Decoding

Custom allows setting a custom Decoding value for edge cases or future specifications. Use this when the predefined constants don't cover your specific use case.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL