Home
Docs
GitHub
Pricing
Blog
Log In

Run Sandworm Audit for your App

Get started
Hold on, we're currently generating a fresh version of this report
Generated on Feb 9, 2024 via pnpm

lodash 4.17.21

Lodash modular utilities.
Package summary
Share
0
issues
1
license
1
MIT
Package created
23 Apr 2012
Version published
20 Feb 2021
Maintainers
3
Total deps
1
Direct deps
0
License
MIT

Issues

0
This package has no issues

Licenses

MIT License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
sublicense
private-use
Cannot
hold-liable
Must
include-copyright
include-license
1 Packages, Including:
lodash@4.17.21
Disclaimer

This deed highlights only some of the key features and terms of the actual license. It is not a license and has no legal value. You should carefully review all of the terms and conditions of the actual license before using the licensed material.

Sandworm is not a law firm and does not provide legal services. Distributing, displaying, or linking to this deed or the license that it summarizes does not create a lawyer-client or any other relationship.

Direct Dependencies

0
All Dependencies CSV
β“˜ This is a list of lodash 's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
NameVersionSizeLicenseTypeVulnerabilities

Visualizations

Frequently Asked Questions

What does lodash do?

Lodash is a powerful utility library for JavaScript, delivering consistency, modularity, and performance to its users. It's designed to simplify the process of manipulating and managing data in JavaScript, and is broadly adopted due to its efficiencies and conveniences. Lodash operations handle arrays, numbers, objects, strings, etc., providing users with a seamless ability to treat nodes of data, no matter how they're represented. The utility functions in Lodash perform tasks ranging from checking types, manipulating arrays, objects and strings, to creating composite functions and more. What else sets Lodash apart is its intricate handling of edge cases, contributing to its robust performance in varied and unanticipated scenarios, adding to its popularity among JavaScript developers.

How do you use lodash?

Lodash can be effortlessly used in Node.js applications. Firstly, you need to install it via npm by running the command npm i --save lodash. Post installation, Lodash functions can be accessed by inserting a require statement into your JavaScript file, such as var _ = require('lodash');. This makes the entirety of the Lodash library available under the underscore (_) variable. However, you may also require specific functions or categories only, to ensure a lighter bundle size when it comes to browserify/rollup/webpack bundles. For instance, to use just the "array" category, use var array = require('lodash/array');, or for a specific function, use var at = require('lodash/at');. Following this, functions can then be called using the format _.functionName().

var _ = require('lodash');

var users = [
  { 'user': 'fred',   'age': 48 },
  { 'user': 'barney', 'age': 36 },
  { 'user': 'fred',   'age': 40 },
  { 'user': 'barney', 'age': 34 }
];

_.sortBy(users, ['user', 'age']);
// => objects for [['barney', 34], ['barney', 36], ['fred', 40], ['fred', 48]]

In this example, the sortBy function is used to order the array of user objects by the user name and age properties.

Where are the lodash docs?

Documentation for Lodash is available on its official website at https://lodash.com/. Here, you'll find an exhaustive list of functions and methods provided by Lodash, with explanations, usage instructions, and examples. Additionally, you can check the package source on GitHub for more details: https://github.com/lodash/lodash/tree/4.17.21-npm. Both these resources are invaluable for learning how to work with Lodash and utilize its various functionalities to make JavaScript programming simpler and more efficient.