Add icon inside alert ok button

hi, can we add icon indie ion-alert ok button in ionic 5

i need to add a icon in frond of agree button

customization bro… well i have achieved this thanks for your reply

1 Like

Do it through javascript. This is the buttonAlert interface

export interface AlertButton {
  text: string;
  role?: 'cancel' | 'destructive' | string;
  cssClass?: string | string[];
  id?: string;
  handler?: (value: any) => AlertButtonOverlayHandler | Promise<AlertButtonOverlayHandler>;

What I would do is to set an id and change the inner html through javascript

document.getElementById("your-button-id").innerHTML = "<ion-icon name="search-outline"></ion-icon>";

Didn’t tried it, but might work.