# get-prototype-chain

> Returns an array of the object's prototype chain

Latest version **1.0.1** (published 2015-09-15) · ISC license · 0 weekly downloads

## Install

```sh
npm install get-prototype-chain
pnpm add get-prototype-chain
yarn add get-prototype-chain
bun add get-prototype-chain
```

## 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.1 |
| Published | 2015-09-15 |
| First published | 2015-09-14 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >=4.0.0 |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 2 |
| Author | Michael Leaney |
| Maintainers | leahcimic |
| Keywords | prototype, chain, properties |

## Links

- npm: https://www.npmjs.com/package/get-prototype-chain
- Repository: https://github.com/leahciMic/get-prototype-chain
- Homepage: https://github.com/leahciMic/get-prototype-chain#readme
- Issues: https://github.com/leahciMic/get-prototype-chain/issues
- npm.io page: https://npm.io/package/get-prototype-chain

## Recent versions

- 1.0.1 (latest) — 2015-09-15
- 1.0.0 — 2015-09-14

## README

# get-prototype-chain [![Build Status](https://travis-ci.org/leahciMic/get-prototype-chain.svg?branch=master)](https://travis-ci.org/leahciMic/get-prototype-chain)

Returns an array with the passed in object's prototype chain (in
ascending order).

## Install

```sh
npm install --save get-prototype-chain
```

## Usage

```js
const getPrototypeChain = require('get-prototype-chain');

class A {

}

class B extends A {

}

class C extends B {

}

var obj = new C();

getPrototypeChain(obj).map(x => x.constructor.name)

// returns ['C', 'C', 'B', 'A', 'Object']
```

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