Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

.jsbeautifyrc file not being used #2

Closed
nquintal opened this issue Dec 23, 2015 · 2 comments
Closed

.jsbeautifyrc file not being used #2

nquintal opened this issue Dec 23, 2015 · 2 comments

Comments

@nquintal
Copy link

I am trying to make VSCodeBeautify take my .jsbeautifyrc file into account inside a Node.JS project.
I cannot seem to find the right place.
I've tried putting it at the root of the folder opened in VSCode.
I've tried putting it inside the .vscode folder.
I've tried putting it at the same level as the package.json.
I've tried restarting VSCode couple times.

None of theses locations seems to do anything.

Here's my .jsbeautifyrc file

// Documentation: https://github.com/einars/js-beautify/
{
    "indent_size": 2,
    "indent_char": " ",
    "eol": "\n",
    "indent_level": 0,
    "indent_with_tabs": false,
    "preserve_newlines": true,
    "max_preserve_newlines": 10,
    "jslint_happy": false,
    "space_after_anon_function": false,
    "brace_style": "collapse",
    "keep_array_indentation": false,
    "keep_function_indentation": false,
    "space_before_conditional": true,
    "break_chained_methods": false,
    "eval_code": false,
    "unescape_strings": false,
    "wrap_line_length": 0,
    "wrap_attributes": "auto",
    "wrap_attributes_indent_size": 4,
    "end_with_newline": false
}
@HookyQR
Copy link
Owner

HookyQR commented Dec 23, 2015

Hi Nicolas,

You should have your .jsbeautifyrc file at the root of your workspace, just as you first did. The location is not the problem. The file you have provided isn't technically valid JSON. A JSON file can't have any comments in it. If you remove the comment line from the top of the file, it should work fine. I'll tweak the code to allow a comment at the top for you though, cos it seems like a fair idea to have the documentation reference there.

@HookyQR HookyQR changed the title Where do I put the .jsbeautifyrc file? .jsbeautifyrc file not being used Dec 23, 2015
@HookyQR
Copy link
Owner

HookyQR commented Dec 23, 2015

version 0.0.5 published to VSCode marketplace.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants