Skip to content

ion-label does not render when binding innerHTML directly #31003

@samizarraa

Description

@samizarraa

Description
I noticed an issue when binding innerHTML directly to ion-label.

Example that does not render text:

<ion-item> <ion-label [innerHTML]="title"></ion-label> </ion-item> However, wrapping the same content inside a native element works correctly: <ion-item> <ion-label> <span [innerHTML]="title"></span> </ion-label> </ion-item> This renders normally. Environment Ionic: @ionic/angular: 8.8.1 Angular: @angular/core: 21.2.1 Capacitor: @capacitor/core: 8.2.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions