Skip to content

Commit

Permalink
Print stringliteral
Browse files Browse the repository at this point in the history
  • Loading branch information
leaysgur committed Dec 17, 2024
1 parent 86c9802 commit 94fc3df
Showing 1 changed file with 5 additions and 11 deletions.
16 changes: 5 additions & 11 deletions crates/oxc_prettier/src/format/js.rs
Original file line number Diff line number Diff line change
Expand Up @@ -928,17 +928,11 @@ impl<'a> Format<'a> for RegExpLiteral<'a> {

impl<'a> Format<'a> for StringLiteral<'a> {
fn format(&self, p: &mut Prettier<'a>) -> Doc<'a> {
wrap!(p, self, StringLiteral, {
literal::replace_end_of_line(
p,
literal::print_string(
p,
self.span.source_text(p.source_text),
p.options.single_quote,
),
JoinSeparator::Literalline,
)
})
literal::replace_end_of_line(
p,
literal::print_string(p, self.span.source_text(p.source_text), p.options.single_quote),
JoinSeparator::Literalline,
)
}
}

Expand Down

0 comments on commit 94fc3df

Please sign in to comment.