Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: binding context vm when using function without parentheses #148

Merged
merged 2 commits into from
Jun 6, 2020

Conversation

pikax
Copy link
Member

@pikax pikax commented Sep 27, 2019

Binding function to the vm context.

Fixes: #144

test/setup.spec.js Outdated Show resolved Hide resolved
@@ -355,4 +355,46 @@ describe('setup', () => {
})
.then(done);
});

describe('Bindings', ()=>{
it('should bind the vm when calling with parentesis', async ()=>{
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
it('should bind the vm when calling with parentesis', async ()=>{
it('binds methods when calling with parenthesis', async ()=>{

test/setup.spec.js Outdated Show resolved Hide resolved
test/setup.spec.js Outdated Show resolved Hide resolved
test/setup.spec.js Outdated Show resolved Hide resolved
Copy link
Member

@posva posva left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

@anhoev
Copy link

anhoev commented Nov 28, 2019

Please merge, i need it because context.slots is not reactive in runtime

@antfu antfu mentioned this pull request Jun 3, 2020
@antfu antfu merged commit 5b269f7 into vuejs:master Jun 6, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Method context dependent on parentheses use
4 participants