tinymce / tinymce-angular

Official TinyMCE Angular Component
MIT License
324 stars 93 forks source link

How to display dynamic value in dialog using angular #225

Closed the-nine-tail closed 3 years ago

the-nine-tail commented 3 years ago

I am trying to display dynamic value in dialog but getting value as undefined.

Code: body: { type: 'panel', items: [{ type: 'alertbanner', // component type level: 'info', text: `${this.myname}`, url: 'http://my.url', icon: 'question' }] },

this.myname should display my name but it shows undefined. I am using tinymce version 5+ integrated with angular 11

tylerkelly13 commented 3 years ago

Hi @the-nine-tail

I'll transfer this issue to the tinymce/tinymce-angular repository so the developers can have a look into this issue.

Tyler

jscasca commented 3 years ago

Hi @the-nine-tail that might be an issue with how you are declaring your variable. Here is a codesandbox of a dialog displaying a dynamic value: https://codesandbox.io/s/tinymceangular-forked-huqsz?file=/src/app/app.component.ts

Let me know if that helps