Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
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
- Host: GitHub
- URL: https://github.com/avin/read-first-line
- Owner: avin
- Created: 2021-05-08T21:37:35.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2021-05-09T13:34:25.000Z (over 3 years ago)
- Last Synced: 2024-08-09T14:05:20.763Z (3 months ago)
- Topics: node
- Language: TypeScript
- Homepage:
- Size: 75.2 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
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);
});
```