Skip to content

Instantly share code, notes, and snippets.

@mofelee
Last active August 29, 2015 14:23
Show Gist options
  • Save mofelee/c1a96b0b1bafd125cff7 to your computer and use it in GitHub Desktop.
Save mofelee/c1a96b0b1bafd125cff7 to your computer and use it in GitHub Desktop.
minimongoInspector
showTable = function(tableName){
var count = 0;
return Tracker.autorun(function(){
// console.clear();
console.table(window[tableName].find().fetch());
count++;
console.log('第' + count + '次刷新', Date())
});
}
/////// 使用方法
//// 监视Lists表 (http://todos.meteor.com/)
// var ListsCtrl = showTable('Lists');
//// 停止检视Lists表
// ListsCtrl.stop();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment