Strip the final newline character from a string/buffer
MIT License
Trim a consecutively repeated substring: foo--bar---baz → foo-bar-baz
Remove leading, trailing and repeated whitespace from a string
Strip leading whitespace from each line in a string
Get stdin as a string or buffer
Strip shebang (eg. #!/bin/sh) from a string
Strip a substring from the start/end of a string
Strip UTF-8 byte order mark (BOM) from a string
Strip UTF-8 byte order mark (BOM) from a stream
Strip console, alert, and debugger statements from JavaScript code
Split lines into an array of lines
Strip UTF-8 byte order mark (BOM)
Strip UTF-8 byte order mark (BOM) from a buffer
Normalize the newline characters in a string to `\n`
Trim newlines from the start and/or end of a string