README
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 @skmmilk1172/lotide
Require it:
const _ = require('@skimmilk1172/lotide');
Call it:
const results = _.tail([1, 2, 3]) // => [2, 3]
Documentation
The following functions are currently implemented:
head.js
: Returns the first element in arraytail.js
: Returns all elements in array besides the headmiddle.js
: Returns the middle element in an arrayfindKeyByValue.js
: Searches an objectand returns a key that contains the given value.findKey.js
: Returns a truthy value, if given an object and callbackeqArray.js
: Compares two given arrays and returns true of false.countOnly.js
: Returns the count of numbers or stringletterPositions.js
: Returns all occurence of when a given value appears in a phraseassertObjectEqual.js
: Takes two objects and returns a message based on what is givenassertEqual.js
: Shows if two given values are identicalassertArraysEqual.js
: Takes 2 arrays and prints message according to input.eqObjects.js
: Returns true of false if both objects are identicalmap.js
: Returns a new array based off callback functiontakeUntil.js
: Returns an array that stops at where the callback is indicating to stop atwithout.js
: Returns back an array that has removed values indicated by callbackpig-latin.js
: Moves first indexed letter to the back of the word, followed by 'ay'reverse.js
: reverses each word in the order it has been placed in.