remove_attr

Remove selected attributes from HTML tags.

Syntax

{{ value | remove_attr:"class" }}{{ value | remove_attr:("class", "style") }}

Example

01

Basic usage

InputTS
1{2  "html": "<div class=\"card\" id=\"intro\">Hello</div>"3}
TemplateKNAP
1{{ html | remove_attr:"class" }}
OutputKNAP
1<div id="intro">Hello</div>