@thinice/normalize-line-endings
v0.1.4
Published
Converts CRLF ↔ LF line endings
Downloads
472
Readme
@thinice/normalize-line-endings
Converts CRLF ↔ LF line endings.
Installation
npm install @thinice/normalize-line-endingsUsage
import { normalizeLineEndings } from "@thinice/normalize-line-endings";
normalizeLineEndings("hello\r\nworld", "lf"); // "hello\nworld"
normalizeLineEndings("hello\nworld", "crlf"); // "hello\r\nworld"Source
https://github.com/thinicejs/utils/tree/main/packages/normalize-line-endings
