-
-
Notifications
You must be signed in to change notification settings - Fork 522
Closed
Labels
Description
I want to access some properties of the component in updateQuery
, but when I'm calliing this in updateQuery
of Subscription, the this
is referring to the object itself. How can I access the component this in the updateQuery
?
subscribeToMore: {
variables () {
console.log('variables.this', this) // it's correct, vue component
return {}
},
updateQuery (result, { subscriptionData }) {
console.log('updateQuery.this', this) // it's wrong, just the object itself, I guess missing binding this
}
}