# lodash.compact

> The lodash method `_.compact` exported as a module.

Latest version **3.0.1** (published 2016-03-02) · MIT license · 0 weekly downloads

> **Better alternative:** See documentation for alternatives (https://github.com/AikidoSec/module-replacements/blob/main/docs/lodash-underscore)

## Install

```sh
npm install lodash.compact
pnpm add lodash.compact
yarn add lodash.compact
bun add lodash.compact
```

## Health

**Score 48/100 (D)** — status: abandoned.

Positive: has types package; no vulnerabilities; high maintenance score; high quality score; popular repo; extremely popular.

Warnings: low downloads; no esm support.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 3.0.1 |
| Published | 2016-03-02 |
| First published | 2013-09-23 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | separate (@types/lodash.compact) |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 61278 |
| Author | John-David Dalton |
| Maintainers | jdalton, mathias, phated |
| Keywords | lodash-modularized, compact |

## Links

- npm: https://www.npmjs.com/package/lodash.compact
- Repository: https://github.com/lodash/lodash
- Homepage: https://lodash.com/
- Issues: https://github.com/lodash/lodash/issues
- npm.io page: https://npm.io/package/lodash.compact

## Alternatives

- [lodash.assign](https://npm.io/package/lodash.assign.md) — 2.3M weekly downloads
- [lodash.chunk](https://npm.io/package/lodash.chunk.md) — 1.8M weekly downloads
- [react-native-ios-utilities](https://npm.io/package/react-native-ios-utilities.md) — 138.5K weekly downloads
- [@technically/lodash](https://npm.io/package/@technically/lodash.md) — 50.9K weekly downloads
- [@fluid-topics/ft-icon](https://npm.io/package/@fluid-topics/ft-icon.md) — 20.6K weekly downloads

## Recent versions

- 3.0.1 (latest) — 2016-03-02
- 3.0.0 — 2015-01-26
- 2.4.1 — 2013-12-03
- 2.4.0 — 2013-11-26
- 2.3.0 — 2013-11-11
- 2.2.1 — 2013-10-03
- 2.2.0 — 2013-09-29
- 2.1.0 — 2013-09-23
- 2.0.0 — 2013-09-23

## README

# lodash.compact v3.0.1

The [lodash](https://lodash.com/) method `_.compact` exported as a [Node.js](https://nodejs.org/) module.

## Installation

Using npm:
```bash
$ {sudo -H} npm i -g npm
$ npm i --save lodash.compact
```

In Node.js:
```js
var compact = require('lodash.compact');
```

See the [documentation](https://lodash.com/docs#compact) or [package source](https://github.com/lodash/lodash/blob/3.0.1-npm-packages/lodash.compact) for more details.

---
_Source: https://npm.io/package/lodash.compact · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
