diff --git a/README.md b/README.md index 31d569069..5d150ac37 100644 --- a/README.md +++ b/README.md @@ -93,6 +93,11 @@ However, when beautification occurs on save then it will be forced to beautify the entire file's contents, not just selected text. +- `disabledLanguages` (Default *empty array*) +An array of Grammar names to disable beautification for. +Note: If using the Atom's Package Settings then an array is +represented as comma-separated string. + - `muteUnsupportedLanguageErrors` (Default *false*) Mute only *unsupported language* errors. diff --git a/lib/language-options.coffee b/lib/language-options.coffee index c1f28dfc3..a717c210f 100644 --- a/lib/language-options.coffee +++ b/lib/language-options.coffee @@ -156,7 +156,7 @@ module.exports = unsupportedGrammar = false options = undefined if atom.config.get("atom-beautify.disabledLanguages").indexOf(grammar) > - 1 - return + return beautifyCompleted(null) switch grammar # Treat JSON as JavaScript, because it will support comments. # And Glavin001 has tested JSON beauifying with beautifyJS.