设置 TAB 为 4 字符,新建 js 文件
- 发布:2020-10-23 12:22
- 更新:2020-10-24 00:32
- 阅读:1854
产品分类: HbuilderX
PC开发环境操作系统: Windows
PC开发环境操作系统版本号: Microsoft Windows [版本 6.1.7601]
HBuilderX版本号: 2.9.3
操作步骤:
预期结果:
TAB 缩进,宽度 4 字符
TAB 缩进,宽度 4 字符
实际结果:
缩进2个空格
缩进2个空格
bug描述:
不论在设置中
HBuilderX 中设置 TAB 的缩进大小无效!一致保持是 2 个字符!
查看设置文件 JSON 代码,参数正常:
{
"adb.path" : "",
"browsers.config" : {
"Chrome.path" : "C:/Users/Administrator/AppData/Local/Google/Chrome/Application/chrome.exe"
},
"editor.colorScheme" : "Atom One Dark",
"editor.fontSize" : 10,
"editor.insertSpaces" : false,
"editor.matchesChars" : "[]''\"\"{}",
"editor.minimap.enabled" : false,
"editor.tabSize" : 4,
"eslint-vue.autoFixOnSave" : false,
"node.path" : "C:/dev-tools/HBuilderX/plugins/node/node.exe",
"npm.path" : "C:/dev-tools/HBuilderX/plugins/npm/npm.cmd",
"terminal.type" : "外部终端",
"weApp.devTools.path" : "C:/dev-tools/weixin-devtools"
}
a***@126.com (作者)
2020-10-23 12:42:03 [LanguageServerProcess] NLS missing message: MetadataReader_ErrorParsingDocumentationXML in: com.aptana.editor.common.contentassist.messages
2020-10-23 12:42:03 [LanguageServerProcess] java.lang.Exception: NLS missing message: MetadataReader_ErrorParsingDocumentationXML in: com.aptana.editor.common.contentassist.messages
at io.dcloud.editor.common.contentassist.MetadataReader.loadXML(MetadataReader.java:234)
at io.dcloud.editor.js.contentassist.index.SDocMLFileIndexingParticipant.requestIndex(SDocMLFileIndexingParticipant.java:59)
at io.dcloud.index.core.AbstractRemoteFileIndexingParticipant.offlineIndex(AbstractRemoteFileIndexingParticipant.java:100)
at io.dcloud.index.core.AbstractRemoteFileIndexingParticipant.index(AbstractRemoteFileIndexingParticipant.java:93)
at io.dcloud.index.core.IndexRequestJob.indexFileStores(IndexRequestJob.java:298)
at io.dcloud.index.core.IndexUrisJob.run(IndexUrisJob.java:55)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)
Caused by: org.xml.sax.SAXParseException; lineNumber: 1; columnNumber: 1; 文件提前结束。
at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(Unknown Source)
at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLScanner.reportFatalError(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$PrologDriver.next(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl.parse(Unknown Source)
at javax.xml.parsers.SAXParser.parse(Unknown Source)
at io.dcloud.editor.common.contentassist.MetadataReader.loadXML(MetadataReader.java:208)
... 6 more
检查下项目下,是否存在.editorconfig文件。
如果项目下配置了.editorconfig,会以editorconfig配置为准。
HBuilderX editorconfig使用说明: https://ask.dcloud.net.cn/article/36070