# find-and-apply

> Recursively search any json structure and make changes at a certain leaf

Latest version **1.0.2** (published 2016-08-26) · ISC license · 0 weekly downloads

## Install

```sh
npm install find-and-apply
pnpm add find-and-apply
yarn add find-and-apply
bun add find-and-apply
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.2 |
| Published | 2016-08-26 |
| First published | 2016-08-26 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Martin Liberg |
| Maintainers | marreman |

## Links

- npm: https://www.npmjs.com/package/find-and-apply
- Repository: https://github.com/marreman/find-and-apply
- Homepage: https://github.com/marreman/find-and-apply#readme
- Issues: https://github.com/marreman/find-and-apply/issues
- npm.io page: https://npm.io/package/find-and-apply

## Recent versions

- 1.0.2 (latest) — 2016-08-26
- 1.0.1 — 2016-08-26
- 1.0.0 — 2016-08-26

## README

# find-and-apply

Recursively search any json structure and make changes at a certain leaf.

## Install
```sh
npm install find-and-apply
```

## Use
```js
const { findAndApply, isObject } = require("find-and-apply")

findAndApply([
  { foo: "bar" },
  { foo: "baz" }
], candidate => (
  isObject(candidate) && candidate.foo === "baz"
), hit => ({
  foo: "banana"
}))

// [{ foo: "bar" }, { foo: "banana" }]
```

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