types don't have trailing newlines

This commit is contained in:
Brian Hicks 2024-04-11 06:25:10 -05:00
parent 757c03c753
commit 47e37a400e
No known key found for this signature in database
GPG Key ID: C4F324B9CAAB0D50
2 changed files with 2 additions and 3 deletions

View File

@ -36,7 +36,7 @@ impl Schema {
.to_source(),
);
buffer.push('\n');
buffer.push_str("\n\n");
buffer.push_str(
&typescript::TSType::new_ref("Flags".to_string())
.into_init()

View File

@ -87,7 +87,6 @@ impl TSType {
out.push_str(name); // TODO: escape?
out.push_str(" = ");
out.push_str(&definition.to_source());
out.push('\n');
}
}
@ -204,7 +203,7 @@ mod tests {
assert_eq!(
type_.to_source(),
"type Flags = {\n a: string;\n}\n".to_string(),
"type Flags = {\n a: string;\n}".to_string(),
)
}
}