Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/avin/read-first-line

Read first line of the file
https://github.com/avin/read-first-line

node

Last synced: 1 day ago
JSON representation

Read first line of the file

Awesome Lists containing this project

README

        

# Read-first-line

Read first line of the file. Works fine with LF and CRLF line endings.

## Install

```sh
npm install read-first-line
```

## Usage

```js
const readFirstLine = require("read-first-line");

readFirstLine("./file.txt").then((result) => {
console.log("first line is: " + result);
});
```