@hanisiddiqui/lotide

1.0.0 • Public • Published

Lotide

A mini clone of the Lodash library.

Purpose

BEWARE: This library was published for learning purposes. It is not intended for use in production-grade software.

This project was created and published by me as part of my learnings at Lighthouse Labs.

Usage

Install it:

npm install @hanisiddiqui/lotide

Require it:

const _ = require('@hanisiddiqui/lotide');

Call it:

const results = _.tail([1, 2, 3]) // => [2, 3]

Documentation

The following functions are currently implemented:

  • assertArraysEqual(...): checks if two arrays are equal
  • assertEqual(...): checks if two values are equal
  • assertObjectsEqual(...): checks if two objects are equal
  • countLetters(...): counts the number of times each letter in a sentence is used
  • countOnly(...): counts the number of times a name is used
  • eqArrays(...): checks if two arrays are equal
  • eqObjects(...): checks if two objects are equal
  • findKey(...): returns key for a specific value
  • findKeyByValue(...): returns key for a specific value
  • head(...): returns first element of array
  • tail(...): returns last element of array
  • map(...): returns first letter of each string
  • indexPositions(...): returns index of each value
  • middle(...): returns middle element(s)
  • takeUntil(...): returns array until certain value
  • without(...): returns array without specific element

Readme

Keywords

none

Package Sidebar

Install

npm i @hanisiddiqui/lotide

Weekly Downloads

0

Version

1.0.0

License

ISC

Unpacked Size

16.3 kB

Total Files

25

Last publish

Collaborators

  • hanisiddiqui