2016-07-27 42 views
0

我试图寻找可能的方式来找到在服务器上显示为[Function]的功能定义。如何在括号内查看功能

Meteor.publish gives [Function] 
on Meteor shell , but how to get the detailed description of function` 

`

+0

你问一个人如何打印功能说出来?如果是这样,我认为你可以简单地调用'functionName.toString()',就像'console.log('func:',myFunction.toString());'它会直接打印出来。 – CodeChimp

+0

谢谢你:) –

回答

0

好像作为@codechimp说,我们可以用Function.toString()