File tree Expand file tree Collapse file tree 3 files changed +36
-2
lines changed
tests/fixtures/js/conditional Expand file tree Collapse file tree 3 files changed +36
-2
lines changed Original file line number Diff line number Diff line change @@ -464,10 +464,10 @@ impl<'a> FormatConditionalLike<'a, '_> {
464464
465465 let format_alternative = format_with ( |f| match self . conditional {
466466 ConditionalLike :: ConditionalExpression ( conditional) => {
467- write ! ( f, [ conditional. alternate( ) ] )
467+ write ! ( f, [ FormatNodeWithoutTrailingComments ( conditional. alternate( ) ) ] )
468468 }
469469 ConditionalLike :: TSConditionalType ( conditional) => {
470- write ! ( f, [ conditional. false_type( ) ] )
470+ write ! ( f, [ FormatNodeWithoutTrailingComments ( conditional. false_type( ) ) ] )
471471 }
472472 } ) ;
473473 let format_alternative = format_with ( |f| {
Original file line number Diff line number Diff line change 1+ cb (
2+ overflowing ? 'absolute top-0' : 'relative' , // sidebar custom changes - to contain the absolute sidebar below
3+ parameter
4+ )
5+
6+ cb (
7+ overflowing ? 'absolute top-0' : 'relative' /* */ , // sidebar custom changes - to contain the absolute sidebar below
8+ parameter
9+ )
Original file line number Diff line number Diff line change 1+ -- -
2+ source : crates / oxc_formatter / tests / fixtures / mod .rs
3+ -- -
4+ ==================== Input ====================
5+ cb (
6+ overflowing ? ' absolute top-0' : ' relative' , // sidebar custom changes - to contain the absolute sidebar below
7+ parameter
8+ )
9+
10+ cb (
11+ overflowing ? ' absolute top-0' : ' relative' /* */ , // sidebar custom changes - to contain the absolute sidebar below
12+ parameter
13+ )
14+ ==================== Output ====================
15+ cb (
16+ overflowing ? " absolute top-0" : " relative" , // sidebar custom changes - to contain the absolute sidebar below
17+ parameter ,
18+ );
19+
20+ cb (
21+ overflowing ? " absolute top-0" : " relative" /* */ , // sidebar custom changes - to contain the absolute sidebar below
22+ parameter ,
23+ );
24+
25+ ===================== End =====================
You can’t perform that action at this time.
0 commit comments