# is-proto-prop

> Does a JS type's prototype have a property

Latest version **3.0.1** (published 2024-05-23) · MIT license · 0 weekly downloads

## Install

```sh
npm install is-proto-prop
pnpm add is-proto-prop
yarn add is-proto-prop
bun add is-proto-prop
```

## Health

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

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 3.0.1 |
| Published | 2024-05-23 |
| First published | 2015-11-01 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Node | >=18.0.0 |
| Dependencies | 2 |
| Unpacked size | 3.7 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Dustin Specker |
| Maintainers | dustinspecker |
| Keywords | js, javascript, proto, properties |

## Links

- npm: https://www.npmjs.com/package/is-proto-prop
- Repository: https://github.com/dustinspecker/is-proto-prop
- Homepage: https://github.com/dustinspecker/is-proto-prop#readme
- Issues: https://github.com/dustinspecker/is-proto-prop/issues
- npm.io page: https://npm.io/package/is-proto-prop

## Dependencies (2)

- [lowercase-keys](https://npm.io/package/lowercase-keys.md) ^3.0.0
- [prototype-properties](https://npm.io/package/prototype-properties.md) ^5.0.0

## Alternatives

- [@mapbox/jsonlint-lines-primitives](https://npm.io/package/@mapbox/jsonlint-lines-primitives.md) — 5.3M weekly downloads
- [reftools](https://npm.io/package/reftools.md) — 3.5M weekly downloads
- [@hey-api/openapi-ts](https://npm.io/package/@hey-api/openapi-ts.md) — 3.5M weekly downloads
- [@mapbox/geojson-rewind](https://npm.io/package/@mapbox/geojson-rewind.md) — 2.4M weekly downloads
- [turbo-stream](https://npm.io/package/turbo-stream.md) — 1.7M weekly downloads

## Recent versions

- 3.0.1 (latest) — 2024-05-23
- 3.0.0 — 2024-05-23
- 2.0.0 — 2018-12-23
- 1.0.1 — 2018-03-01
- 1.0.0 — 2015-11-01

## README

# is-proto-prop
[![NPM version](https://badge.fury.io/js/is-proto-prop.svg)](https://badge.fury.io/js/is-proto-prop) [![Coverage Status](https://img.shields.io/coveralls/dustinspecker/is-proto-prop.svg)](https://coveralls.io/r/dustinspecker/is-proto-prop?branch=master)

[![Code Climate](https://codeclimate.com/github/dustinspecker/is-proto-prop/badges/gpa.svg)](https://codeclimate.com/github/dustinspecker/is-proto-prop)

> Does a JS type's prototype have a property

## Install
```
npm install --save is-proto-prop
```

## Usage
### ES2015
```javascript
import isProtoProp from 'is-proto-prop';

isProtoProp('array', 'length');
// => true

isProtoProp('Error', 'ignore');
// => false

// `is-proto-props` can only verify native JS types
isProtoProp('gulp', 'task');
// => false
```

## API
### isProtoProp(type, propertyName)
Returns a `Boolean` if `propertyName` is on `type`'s prototype.

#### type
type: `string`

JS type to examine the prototype of. Note: `is-proto-prop` only looks at native JS types.

#### propertyName
type: `string`

Property name to look for on `type`'s prototype. Note: `propertyName` is case sensitive.

## LICENSE
MIT © [Dustin Specker](https://github.com/dustinspecker)

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