Forum Academy Marketplace Showcase Pricing Features

instance.data.getData is not a function

I saw this code on person’s working plugin:


So I tried implementing it:
a3
a4
But it returns this:

Can anyone help?

Update: instance.data doesn’t work at all for me for some reason. Always says “undefined” even if it’s not a function.

Try this.

In your initialize block enter the code

instance.data.message = ‘hello world’

And then create an action called print

In your “print” action put the code

console.log(instance.data.message)

Does that do anything for you?

No, for some reason, it doesn’t:
a6

Can you share access to your plugin? If you add me as a collaborator, I’d be happy to give it a check.

I use this type of operation quite regularly to pass around full blown objects with functions or whatever else info I need to share between functions