Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit6731444

Browse files
ayamflowFlorian Morel
authored and
Florian Morel
committed
Allow Vue.nextTick to be passed a context
1 parentc8a168b commit6731444

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

‎src/utils.js‎

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -247,8 +247,13 @@ var utils = module.exports = {
247247
/**
248248
* used to defer batch updates
249249
*/
250-
nextTick:function(cb){
251-
defer(cb,0)
250+
nextTick:function(cb,context){
251+
if(context){
252+
defer(utils.bind(cb,context),0)
253+
}
254+
else{
255+
defer(cb,0)
256+
}
252257
},
253258

254259
/**
@@ -310,7 +315,7 @@ function enableDebug () {
310315
console.log(msg)
311316
}
312317
}
313-
318+
314319
/**
315320
* warnings, traces by default
316321
* can be suppressed by `silent` option.

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp