How do I change Eclipse to use spaces instead of tabs in Javascript editor?(如何更改 Eclipse 以在 Javascript 编辑器中使用空格而不是制表符?)
问题描述
我使用 Eclipse JavaScript 插件,我将文本编辑器设置为将空格作为制表符插入",这工作正常,直到我选择一段代码并将其制表符或切换制表符,运行 JSLint 和 AARGghh!混合空格和制表符."有什么我想念的吗,这可能吗?
I use the Eclipse JavaScript plugin, I have my text editor settings to "insert spaces as tabs" this works fine until I select a block of code and tab it or shift tab it, run JSLint and AARGghh! "Mixed spaces and tabs." is there something I am missing, is this possible?
推荐答案
我不确定你在哪里设置了编辑器属性插入空格作为制表符".要设置选项卡策略,您需要转到 Window >偏好>Javascript >代码风格 >格式化程序
,创建一个新的配置文件,编辑它并将选项卡策略设置为仅限空格".现在在使用 tab 键时会插入空格.
I am not exactly sure where you set the editor property "insert spaces as tabs". To set the tab policy you need to go to Window > Preferences > Javascript > Code Style > Formatter
, create a new profile, edit it and set the Tab policy to "spaces only". Now when using the tab key spaces are inserted.
这篇关于如何更改 Eclipse 以在 Javascript 编辑器中使用空格而不是制表符?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:如何更改 Eclipse 以在 Javascript 编辑器中使用空格而不是制表符?


- Java包名称中单词分隔符的约定是什么? 2022-01-01
- C++ 和 Java 进程之间的共享内存 2022-01-01
- Jersey REST 客户端:发布多部分数据 2022-01-01
- value & 是什么意思?0xff 在 Java 中做什么? 2022-01-01
- Eclipse 插件更新错误日志在哪里? 2022-01-01
- Spring Boot连接到使用仲裁器运行的MongoDB副本集 2022-01-01
- 如何使用WebFilter实现授权头检查 2022-01-01
- Safepoint+stats 日志,输出 JDK12 中没有 vmop 操作 2022-01-01
- 将log4j 1.2配置转换为log4j 2配置 2022-01-01
- 从 finally 块返回时 Java 的奇怪行为 2022-01-01