Files
test-repo/changelog_unreleased/javascript/pr-8069.md
T

607 B

Fix end-of-line comments if followed by trailing whitespace (#8069 by @shisama)

If comments line has trailing whitespaces, comments aren't detected as end-of-line.

// Input
var a = { /* extra whitespace --> */  
    b };

var a = { /* no whitespace --> */
    b };

// Prettier stable
var a = {
  /* extra whitespace --> */

  b,
};

var a = {
  /* no whitespace --> */ b,
};

// Prettier master
var a = {
  /* extra whitespace --> */ b,
};

var a = {
  /* no whitespace --> */ b,
};