1.0.0 • Published 3 years ago
@raejkhan96/lotide v1.0.0
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 @raejkhan96/lotide
Require it:
const _ = require('@raejkhan96/lotide');
Call it:
const results = _.tail([1, 2, 3]) // => [2, 3]
Documentation
The following functions are currently implemented:
- head: Return 0th index of array
- tail: Return from 1st index to last of array
- middle: Return middle of array
- assertObjectsEqual: check if objects with arrays are equal
- assertEqual: check if values are equal
- countLetters: count amount of letters in string
- eqArrays: check if arrays are equal
- eqObjects: check if objects are equal
- findKey: finds key from given value within object of objects
- findKeyByValue: find key from given value of regular object
- letter Positions: find position of letters given a string
- map: obtain first letter of each word from array
- takeUntil: obtain string up until the character specified
- without: subtract the arrays given
1.0.0
3 years ago