Knap.md
LogicFiltersVariablesAPIGitHub ↗

Guide

VariablesLogicFilters

Reference

API

Project

GitHub ↗npm ↗

image

Create Markdown image syntax from a URL, array, or object.

Filters/image

Syntax

{{ value | image }}{{ value | image:"Alt text" }}

Example

01

Basic usage

InputTS
1{2  "url": "cover.jpg"3}
TemplateKNAP
1{{ url | image:"Cover art" }}
OutputKNAP
1![Cover art](cover.jpg)

Behavior

  • The optional parameter is alt text for string and array inputs.

Related filters

linkCreate Markdown links from a URL, array, or object.
Previous← fragment_linkNextlink →
Knap is open source under the MIT license.View source ↗

On this page

SyntaxExamplesBehaviorRelated filters
image filter — Knap