(text: string)
| 20 | import * as Bom from "@/util/bom" |
| 21 | |
| 22 | function normalizeLineEndings(text: string): string { |
| 23 | return text.replaceAll("\r\n", "\n") |
| 24 | } |
| 25 | |
| 26 | function detectLineEnding(text: string): "\n" | "\r\n" { |
| 27 | return text.includes("\r\n") ? "\r\n" : "\n" |