Category "lodash"

flatten nested object using lodash

flatten, flattenDeep or flattenDepth of lodash only accept array. How to flatten nested object? var data = { "dates": { "expiry_date": "30 sep 2018",

Cypress: Module not found: Error: Can't resolve 'cypress/types/lodash

I am running my first test in Cypress from VS IDE and Cypress was working while until I encountered the error below without having changed or updated anything..

Sort array of objects with date field by date

Give the following array of objects, I need to sort them by the date field ascending. var myArray = [ { name: "Joe Blow", date: "Mon Oct 31 2016 00:0

Renaming several keys in an array/object with Lodash

How can I get from x to y with Lodash? var x = [ {id: 22, location: 'Vienna'}, {id: 13, location: 'London'}, {id: 21, location: 'Paris'} ]; var y

Map an array of arrays

Is there a method in lodash to map over an array of arrays I would like to do something like this so that it keeps the structure of the array. def double(x) {

Lodash.cloneDeep: unable to edit property of cloned object [discord.js execute command]

I'm currently trying to make an ~execute command for my bot. This command will allow me to execute commands as other users, thereby allowing to provide better d