括号中的HTML Beautify设置

时间:2015-07-01 08:23:29

标签: settings adobe-brackets js-beautify

我了解Brackets Beautify扩展程序基于JS Beautify,并且我有一套可用的首选项设置,但我不知道如何通过Brackets设置更改它们.json文件。有没有人有任何想法?

以下是我目前的设置:

   {
        "debug.showErrorsInStatusBar": false,
        "linting.collapsed": true,
        "wordWrap": false,
        "me.drewh.jsbeautify.on_save": false,
        "styleActiveLine": true,
        "themes.theme": "explicit-brackets-style",
        "fonts.fontSize": "12px"
    }

我假设我只需要添加新的“me.drewh.jsbeautify”行,但这似乎不起作用......

我特别关注HTML设置,BTW。

1 个答案:

答案 0 :(得分:3)

与原始library一样,扩展程序使用.jsbeautifyrc文件进行设置。

如果您在项目根目录中使用以下内容创建此类文件,它应该有效:

{
    "eol": "\n",
    "end_with_newline": true,
    "preserve_newlines": true,
    "max_preserve_newlines": 10,
    "indent_inner_html": false,
    "brace_style": "collapse",
    "indent_scripts": "normal",
    "wrap_line_length": 0,
    "wrap_attributes": "auto"
}

此外,我只建议您查看我的fork该扩展程序,因为它允许more detailed settings