πŸš€ 8.9 Released! β†’ ⚑️ New Node-API Engine Preview, πŸ“² ns widget ios, πŸ’… Tailwind v4 and more...
Read Announcement

<HtmlView> is a UI component for rendering simple static HTML content.

TIP

For additional features and improved performance, consider using an alternative implementation like the @nativescript-community/ui-label from the community.

See also: WebView.

xml
<HtmlViewhtml="{{ htmlString }}" />
ts
consthtmlString=`
<h1 style="color: black; font-family: ui-sans-serif, system-ui;">
 <span style="color: #65adf1;">Html</span>View
</h1>
`
html
<HtmlView[html]="htmlString" />
ts
htmlString =`
<h1 style="color: black; font-family: ui-sans-serif, system-ui;">
 <span style="color: #65adf1;">Html</span>View
</h1>
`
tsx
<htmlViewhtml={htmlString}></htmlView>
tsx
<htmlviewhtml={htmlString}></htmlview>
svelte
<htmlViewhtml={htmlString}></htmlView>
vue
<HtmlView :html="htmlString"/>

Props ​

html ​

ts
html: string

The HTML content to be shown.

selectable ​

ts
selectable: boolean

Gets or sets a value indicating whether HtmlView content is selectable.

...Inherited ​

For additional inherited properties, refer to the API Reference.

Native component ​

Previous
DatePicker
On this page
  1. Props
    1. html
    2. selectable
    3. ...Inherited
  2. Native component

Contributors

Edit this page

Last updated:

AltStyle γ«γ‚ˆγ£γ¦ε€‰ζ›γ•γ‚ŒγŸγƒšγƒΌγ‚Έ (->γ‚ͺγƒͺγ‚ΈγƒŠγƒ«) /