We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents a93f095 + 3068644 commit 616e424Copy full SHA for 616e424
stringify.ts
@@ -1,8 +1,11 @@
1
export type ContentLine = [string, string];
2
3
+function foldLine(line: string) {
4
+ return line.match(/(.{1,75})/g)!.join('\r\n ');
5
+}
6
+
7
function stringifyLine(line: ContentLine) {
- // TODO: Handle lines longer than 75 bytes
- return `${line[0]}:${line[1]}`;
8
+ return foldLine(`${line[0]}:${line[1]}`);
9
}
10
11
export function stringifyLines(lines: ContentLine[]) {
0 commit comments