如何在我的代码中找到特定的 Javascript
问题是我有一个巨大的 Javascript 代码,它被分解成许多文件。
我似乎无法找到特定的 javascript 代码在哪里。
如果你处在我的位置,你会如何寻找?
我安装了 firebug lite,但不知道如何使用它。谢谢。
PS 由于某种原因我无法对此发表评论。对不起。
The problem is that I have a huge Javascript code, it's broken down into many files.
And I can't seem to find where a particular javascript code is .
How would you go about finding if you were in my place?
I have the firebug lite installed but no clue how to use it. Thank you.
P.S. I'm not able to comment on SO for some reason. Sorry.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(4)
查看此链接,特别是以下标题:
查找脚本: 搜索脚本:
Check out this link, specifically these headlines:
Find scripts: Search scripts:
我会使用带有在文件中查找选项的文本编辑器,例如
I would use a text editor with a Find In Files option like Notepad++. Most IDEs would also provide this search option.
总会有:
grep -r 'function myHardtoFindFunction(' src/
。在 unix 系统或其他具有 GNU 实用程序的系统上,
there's always:
grep -r 'function myHardtoFindFunction(' src/
on a unix system or another system with GNU utilities.
你可以在firebug搜索框中搜索函数名称,它也会在多个js文件中搜索,
只需打开firebug,右侧应该是一个搜索框。如果您雄心勃勃,甚至还有用于搜索多个文件、不区分大小写和使用正则表达式的复选框。
you can search for function names in the firebug search box, which will also search across multiple js files
just open firebug and on the right hand side should be a searchbox. there are even check boxes for searching multiple files, case insensitivity and the use of regex if you feel ambitious.