# nestcheck

> A small utility to do a deep nest check on an object without throwing a TypeError

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

## Install

```sh
npm install nestcheck
pnpm add nestcheck
yarn add nestcheck
bun add nestcheck
```

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.3.5 |
| Published | 2016-03-02 |
| First published | 2015-10-15 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Jordan L Piepkow |
| Maintainers | jpiepkow |
| Keywords | Object, type, error, nest, check |

## Links

- npm: https://www.npmjs.com/package/nestcheck
- Repository: https://github.com/jpiepkow/nestcheck
- Homepage: https://github.com/jpiepkow/nestcheck#readme
- Issues: https://github.com/jpiepkow/nestcheck/issues
- npm.io page: https://npm.io/package/nestcheck

## Alternatives

- [@sentry/react-native](https://npm.io/package/@sentry/react-native.md) — 2.6M weekly downloads
- [@ardatan/aggregate-error](https://npm.io/package/@ardatan/aggregate-error.md) — 708.1K weekly downloads
- [custom-error-generator](https://npm.io/package/custom-error-generator.md) — 2.0K weekly downloads
- [@technik-sde/prosemirror-recreate-transform](https://npm.io/package/@technik-sde/prosemirror-recreate-transform.md) — 1.5K weekly downloads
- [@suchipi/error-utils](https://npm.io/package/@suchipi/error-utils.md) — 78 weekly downloads

## Recent versions

- 0.3.5 (latest) — 2016-03-02
- 0.3.0 — 2016-02-24
- 0.2.5 — 2016-02-17
- 0.2.4 — 2016-01-08
- 0.2.3 — 2015-10-15
- 0.2.2 — 2015-10-15
- 0.2.1 — 2015-10-15
- 0.2.0 — 2015-10-15
- 0.1.0 — 2015-10-15

## README

NestCheck
===========

npm install nestcheck --save

In code:
var nest = require('nestcheck');


##Description

This module is used to run a deep nest check on objects without throwing a TypeError.

Two functions exist. has and get

has returns a boolean value based on if the nest exists.

git returns the nested value if it exists and if not returns undefined.

##has

nest.has(OBJECT, 'string.of.nest.search') //returns true or false.

##get

nest.get(OBJECT, 'string.of.nest.search') //returns nest value or undefined

##IMPORTANT

Do not include base object name in string search. 

Ex.

	var Obj = {
		nested: { exists: true}
	}
	
	RIGHT
	--------------
	nest.has(Obj, 'nested.exists') //returns true
	
	WRONG
	--------------
	nest.has(Obj, 'Obj.nested') //will return false

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