vue-sonner icon indicating copy to clipboard operation
vue-sonner copied to clipboard

Add easy feature

Open pezexd opened this issue 2 years ago • 2 comments

Would be a prop called parseHTML to read descriptions or messages as html.

[types.ts] export interface ToastT { ..., parseHtml: boolean }

[Toast.vue] <template v-if="toast.description"> <template v-if="toast.parseHtml"> <div data-description="" :class="descriptionClass + toastDescriptionClass" v-html="toast.description" /> </template> <template v-else> <div data-description="" :class="descriptionClass + toastDescriptionClass"> {{ toast.description }} </div> </template> </template>

pezexd avatar Aug 22 '23 20:08 pezexd

With the new release, you can do it by checking out docs and search for Custom with props

sadeghbarati avatar Mar 01 '24 16:03 sadeghbarati

Hi there Thanks for the good product

Was html description implemented or is it achievable only via Custom Component and h() function?

altrusl avatar Sep 01 '24 02:09 altrusl