Using a HtmlView requires the html-view module.

import * as htmlViewModule from "tns-core-modules/ui/html-view";

Declaring a HtmlView.

      <HtmlView html="{{ htmlString }}" />

Creating a HtmlView

var htmlView = new htmlViewModule.HtmlView();

Using HtmlView

htmlView.html = '<span><font color="#ff0000">Test</font></span>';
Is this article helpful? Yes / No
Thank you for your feedback!

Tell us how we can improve this article

NativeScript is licensed under the Apache 2.0 license .
© Progress Software Corporation. All Rights Reserved.