Indented blocks of code aren't uniformly re-indented #23

Closed
nex3 opened this Issue Aug 10, 2010 · 3 comments

Comments

Projects
None yet
5 participants

nex3 commented Aug 10, 2010

Suppose I have the following JS file:

/** Wrap everything in a function for some reason */
(function() {
  var state = 0;

  /** Increment state by 1 */
  function inc() {
    state++;
    return state;
  };

  /** Publically expose `inc` */
  return inc;
})();

The documentation generated for inc is improperly indented. The first line isn't indented at all, but the rest is indented at the same level as the file, so it ends up looking like this:

function inc() {
    state++;
    return state;
  };

It would be preferable to either not remove the indentation on the first line, or to re-indent the entire thing.

aearly commented Dec 10, 2012

I'm going to create a pull request to fix this issue. I'll probably add a CLI flag for it.

Contributor

ForbesLindesay commented Dec 10, 2012

Cool, you might want to check out #59

Owner

tj commented Dec 10, 2012

hmm yeah definitely a bug

@evindor evindor closed this Sep 4, 2014

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