📜  树枝数据 uri - CSS 代码示例

📅  最后修改于: 2022-03-11 14:47:49.933000             🧑  作者: Mango

代码示例1
{{ image_data|data_uri }}

{{ source('path_to_image')|data_uri }}

{# force the mime type, disable the guessing of the mime type #}
{{ image_data|data_uri(mime="image/svg") }}

{# also works with plain text #}
{{ 'foobar'|data_uri(mime="text/html") }}

{# add some extra parameters #}
{{ 'foobar'|data_uri(mime="text/html", parameters={charset: "ascii"}) }}