jiangmiao / simple-javascript-indenter

A vim javascript indent script
http://www.vim.org/scripts/script.php?script_id=3227
72 stars 8 forks source link

Bad indentation for object definition #10

Open chrisyip opened 12 years ago

chrisyip commented 12 years ago

Environment: Win7 + gVim 7.3 Script version: 1.4.6

See screenshot: http://minus.com/mbkxBCRmSn#1

Description I have the below code but the indentation is wrong:

var _form = this
  , $form = $(this)
  , options = {
        a: 1
      , b: 2
    }
    ;

  $form.bind('submit', function(){});

What I expected:

var _form = this
  , $form = $(this)
  , options = {
        a: 1
      , b: 2
    }
  ;

$form.bind('submit', function(){});