0.1.1 • Published 3 years ago
@annexe/array.first v0.1.1
@annexe/first
A utility function to acquire and return the first value in an array.
Installation
To install @annexe/first:
Yarn
yarn add @annexe/first
NPM
npm install @annexe/first
Usage
import { first } from '@annexe/first';
const myArray = [1, 2, 3, 4, 5];
console.log(first<number>(myArray)); // logs 1
0.1.1
3 years ago