Resource Loading
decoding="sync"
Hints that an image should be decoded before presenting the associated rendering update. This may delay presentation; it is not a guarantee of synchronous JavaScript execution. On img; missing or invalid values use auto. Decoding and network fetching are different steps. The inline example demonstrates syntax, not timing.
Formal Syntax & Structure
html syntaxhtml
decoding="sync"Parameters & Attributes
| Name | Type | Description |
|---|---|---|
| decoding | keyword | Hints that an image should be decoded before presenting the associated rendering update. This may delay presentation; it is not a guarantee of synchronous JavaScript execution. |
Working Example
Example Snippethtml
<img src="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxNjAiIGhlaWdodD0iMTAwIj48cmVjdCB3aWR0aD0iMTYwIiBoZWlnaHQ9IjEwMCIgZmlsbD0ibGlnaHRibHVlIi8+PGNpcmNsZSBjeD0iODAiIGN5PSI1MCIgcj0iMzAiIGZpbGw9Im5hdnkiLz48L3N2Zz4=" alt="Blue circle on a light blue background" width="160" height="100" decoding="sync">