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

wrap_line_length breaking in confusing places #103

Closed
jackocnr opened this issue Mar 20, 2014 · 3 comments
Closed

wrap_line_length breaking in confusing places #103

jackocnr opened this issue Mar 20, 2014 · 3 comments

Comments

@jackocnr
Copy link

It breaks after negation e.g.

if ( .... lots of conditions here ... && !someVar) {

becomes

if ( .... lots of conditions here ... && !
    someVar) {

and also before property names e.g.

if ( .... lots of conditions here ... && someVar.someProperty) {

becomes

if ( .... lots of conditions here ... && someVar
    .someProperty) {

Both make the code way less readable. Perhaps it should only break on spaces? Or between logical operators e.g. && or ||?

@jdavisclark
Copy link
Owner

ultimately this is going to be an einars/js-beautify issue. I'll open an issue up there and reference this one.

@webbushka
Copy link

Having a similar issue with ES6 modules something like this

var App = function(){};

export default App;

turns into:

var App = function(){};

export
default App;

is this also a js-beautify issue?

@jdavisclark
Copy link
Owner

@webbushka yes, but this is a separate issue. Looks like beautifier/js-beautify#382 is already open to address this.

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

3 participants