【发布时间】:2017-12-16 01:40:25
【问题描述】:
如何在 sublime 中获取所有调用者函数列表
举例
file a.js
funtion hello(){}
file b.js
hello()
file c.js
hello()
这里函数 hello 调用到文件 b 和文件 c 以及行号
我们如何在 sublime 中得到这个列表
【问题讨论】:
标签: javascript node.js sublimetext3 sublimetext2
如何在 sublime 中获取所有调用者函数列表
举例
file a.js
funtion hello(){}
file b.js
hello()
file c.js
hello()
这里函数 hello 调用到文件 b 和文件 c 以及行号
我们如何在 sublime 中得到这个列表
【问题讨论】:
标签: javascript node.js sublimetext3 sublimetext2
这不是正确的方法,而是使用全局查找选项。然后你会看到每个文件。
但“查找用法”可能是 sublime 的一个包...在包管理器中搜索。
其他选项是将 IDE 更改为 WebStorm 或类似的并使用“查找用法”
最后在函数内放置一个控制台日志,并使用 .caller 属性,您应该看到 origin ,只有当不在顶层时!
【讨论】: