V
V
VegasChickiChicki2019-09-30 20:34:04
JavaScript
VegasChickiChicki, 2019-09-30 20:34:04

How to get this from a higher context level?

Perhaps the description is a little wrong, but I do not know how to describe it more accurately.
I use Vue, the component has data:

data: function () {
            return{
                suggestionOptions: {
                    onSelect (suggestion) {
                        document.querySelector('#index').value = suggestion.data.postal_code;
                    },
                },
            }
        },

I connected the plugin and in the options one of the options is a function.
She has her this. I need to assign a value from data or from store to what it gives out. It gives out what after is equal to now, with a certain plug-in action. I can’t understand how I can get in it not ITS this, but the one that is “above”, this Vue component. I hope I explained clearly.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
M
Michael, 2019-09-30
@VegasChickiChicki

onSelect: () => {}

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question