FontAsset
class FontAsset implements Asset, HtmlRenderable
Web font file.
Properties
| $mimeType |
Methods
__construct(string $url, string|null $file = null, string|null $mimeType = null, string|null $integrity = null, string|bool|null $crossorigin = null)
No description
string
__toString()
Returns the asset URL.
Html
getImportElement()
Returns the HTML element used to import the asset (img, script, link rel="stylesheet", etc.).
Html
getPreloadElement()
Returns the HTML element used to preload the asset (link rel="preload" or rel="modulepreload").
Details
at line 16
__construct(string $url, string|null $file = null, string|null $mimeType = null, string|null $integrity = null, string|bool|null $crossorigin = null)
No description
at line 28
string
__toString()
Returns the asset URL.
at line 34
Html
getImportElement()
Returns the HTML element used to import the asset (img, script, link rel="stylesheet", etc.).
at line 47
Html
getPreloadElement()
Returns the HTML element used to preload the asset (link rel="preload" or rel="modulepreload").