~~ lineWidth: 40 ~~ == should get comments on first line == const u = [ // testing test ]; [expect] const u = [ // testing test, ]; == should format any comments inside when single line == const t = [/*1*/]; [expect] const t = [/*1*/]; == multiple block comments should have a space separator == [/*1*//*2*/] [expect] [/*1*/ /*2*/]; == should format multi-line when the comment extends past the line width == const t = [/*testing this out with a long comment*/]; [expect] const t = [ /*testing this out with a long comment*/ ]; == should format comments inside when multi-line == const u = [ // 0 /*1*/ /*2*/ /*3*/ // 4 /*5*/]; [expect] const u = [ // 0 /*1*/ /*2*/ /*3*/ // 4 /*5*/ ]; == should not parse first comment as trailing when it's a comment block == const u = [ /* 1 */ /* 2 */ // 3 ]; [expect] const u = [ /* 1 */ /* 2 */ // 3 ]; == should format trailing comments of the last member == const u = [ test, // 5 /*test*/] [expect] const u = [ test, // 5 /*test*/ ]; == should handle comments in the place of a member == const u = [ /* 0 */, // test /* 1 */, // 2 /* 3 */, // 4 /* 5 */ ]; [expect] const u = [ /* 0 */, // test /* 1 */, // 2 /* 3 */, // 4 /* 5 */ ];