1.0.0 • Published 2 years ago

@shafsaud/lotide v1.0.0

Weekly downloads
-
License
ISC
Repository
github
Last release
2 years ago

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 @shafsaud/lotide

Require it:

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

Call it:

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

Documentation

The following functions are currently implemented:

  • function1(head): To find first element in an array
  • function2(tail): To find last elements in an array
  • function3(middle):To find mid of an array
  • function4(without): Funtion filterout
  • function5(takeUntil): description
  • function6(map): Function to map
  • function7(flatten): Function to flat an object
  • function8(letterPositions): Find position of a letter
  • function9(findKey): Find by key in an object
  • function10(countOnly): Function to count
  • function11(countLetter): To count letters in a string
  • function12(assertObjectsEqual): A function for assertion and testing.
  • function13(assertArraysEqual): A function for assertion and testing.
  • function14(assertEqual): A function for assertion and testing.
  • function15(eqObjects): A function for assertion and testing.
  • function15(eqArrays): A function for assertion and testing.