您使用的是哪个 Javascript / Chrome 扩展 IDE?

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/5457652/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-10-25 17:15:46  来源:igfitidea点击:

Which Javascript / Chrome Extension IDE are you using?

javascriptgoogle-chrome-extensionide

提问by Sindar

I'm currently develloping a Chrome Extension and i'm searching for more ergonomy by finding a good IDE who can manage javascript and also Chrome Extension API.

我目前正在开发一个 Chrome 扩展程序,我正在通过寻找一个可以管理 javascript 和 Chrome 扩展程序 API 的好的 IDE 来寻找更多的人体工程学。

Thanks in advance.

提前致谢。

回答by Jan

Use Aptana Studioand add the following scripts to File references.

使用Aptana Studio并将以下脚本添加到文件引用。

Add to File References

添加到文件引用

Congratulations! You now have a very capable javascript editor with autocomplete support for chrome APIs

恭喜!您现在拥有了一个非常强大的 javascript 编辑器,并支持 chrome API 的自动完成

enter image description here

在此处输入图片说明

EDIT

编辑

You can have the same functionality in Visual Studio, which has (in my opinion) even better support for javascript. In fact I think it's the best javascript editor around (quiet an achievement for microsoft :))

您可以在 Visual Studio 中使用相同的功能,它(在我看来)对 javascript 的支持甚至更好。事实上,我认为它是最好的 javascript 编辑器(对微软来说是一个安静的成就 :))

Just add the following comment to your js files:

只需将以下注释添加到您的 js 文件中:

/// <reference path="MyExternalFile.js" />

And you get:

你会得到:

extern in VS2010

VS2010 中的外部

回答by Jazzepi

I got this to work on IntelliJ by using this API stub (to make the chrome object appear in auto completion)

我通过使用这个 API 存根让它在 IntelliJ 上工作(使 chrome 对象出现在自动完成中)

https://github.com/linux-china/chrome_js_api_stub

https://github.com/linux-china/chrome_js_api_stub

In combination with the chrome extension.js

结合chrome extension.js

https://code.google.com/p/closure-compiler/source/browse/contrib/externs/chrome_extensions.js

https://code.google.com/p/closure-compiler/source/browse/contrib/externs/chrome_extensions.js

I then added the stub chrome_js_api_stub library and the chrome extension library by following the below directions

然后我按照以下说明添加了存根 chrome_js_api_stub 库和 chrome 扩展库

http://www.jetbrains.com/idea/webhelp/configuring-javascript-libraries.html

http://www.jetbrains.com/idea/webhelp/configuring-javascript-libraries.html

回答by Graza

It's not for everyone, but if by ergonomy you mean moving your hands around as little as possible, not reaching for the mouse, VIM is very much designed to keep your fingers on the keyboard and as close to the asdf/jkl; positions as much as possible. It's a pretty steep learning curve, but the payoff is extremely quick workflow.

它并不适合所有人,但如果按照人体工程学,你的意思是尽可能少地移动你的手,而不是去触碰鼠标,VIM 的设计目的是让你的手指保持在键盘上并尽可能靠近 asdf/jkl;尽可能多的位置。这是一个非常陡峭的学习曲线,但回报是非常快速的工作流程。

With the right addons, it's a very decent javascript editor, with syntax highlighting (including jsdoc comments), code completion, jslint integration, etc

使用正确的插件,它是一个非常不错的 javascript 编辑器,具有语法突出显示(包括 jsdoc 注释)、代码完成、jslint 集成等

回答by M J

For Aptana Studio 3: (plugin for Eclipse tested)

对于 Aptana Studio 3:(测试 Eclipse 插件)

Find a library you are interested in...Save it to your disk, and then drag it into your project. It does not matter where in the project it sits, so you can create a new folder for files like this if you like.

找到您感兴趣的库...将其保存到您的磁盘,然后将其拖到您的项目中。它位于项目中的哪个位置并不重要,因此您可以根据需要为此类文件创建一个新文件夹。

!! The project must be some type of web project: Web, PHP, Python, Ruby, Rails.

!! 该项目必须是某种类型的 Web 项目:Web、PHP、Python、Ruby、Rails。

http://wiki.appcelerator.org/display/tis/Using+JavaScript+Libraries

http://wiki.appcelerator.org/display/tis/Using+JavaScript+Libraries