5 lines
89 B
TypeScript
5 lines
89 B
TypeScript
|
|
export function nl2br(text: string): string {
|
|
return text.replace(/\n/g, "<br>");
|
|
}
|