# pretty-immutable

> Pretty printing for ImmutableJS

Latest version **1.0.1** (published 2016-06-15) · MIT license · 0 weekly downloads

## Install

```sh
npm install pretty-immutable
pnpm add pretty-immutable
yarn add pretty-immutable
bun add pretty-immutable
```

## 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 | 2016-06-15 |
| First published | 2016-06-15 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 2 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 12 |
| Author | Glen Mailer |
| Maintainers | glenjamin |
| Keywords | immutable, pretty, print |

## Links

- npm: https://www.npmjs.com/package/pretty-immutable
- Repository: https://github.com/glenjamin/pretty-immutable
- Homepage: https://github.com/glenjamin/pretty-immutable#readme
- Issues: https://github.com/glenjamin/pretty-immutable/issues
- npm.io page: https://npm.io/package/pretty-immutable

## Dependencies (2)

- [repeat-string](https://npm.io/package/repeat-string.md) ^1.5.4
- [json-stringify-pretty-compact](https://npm.io/package/json-stringify-pretty-compact.md) ^1.0.1

## Alternatives

- [@lexical/table](https://npm.io/package/@lexical/table.md) — 3.0M weekly downloads
- [mantine-datatable](https://npm.io/package/mantine-datatable.md) — 98.2K weekly downloads
- [react-native-collapsible-tab-view](https://npm.io/package/react-native-collapsible-tab-view.md) — 70.6K weekly downloads
- [@handsontable/vue3](https://npm.io/package/@handsontable/vue3.md) — 16.1K weekly downloads
- [vuewordcloud](https://npm.io/package/vuewordcloud.md) — 7.2K weekly downloads

## Recent versions

- 1.0.1 (latest) — 2016-06-15
- 1.0.0 — 2016-06-15

## README

# pretty-immutable

Pretty printing for ImmutableJS

Heavily inspired by (and dependent on) [json-stringify-pretty-compact](https://github.com/lydell/json-stringify-pretty-compact).

[![npm version](https://img.shields.io/npm/v/pretty-immutable.svg)](https://www.npmjs.com/package/pretty-immutable) [![Build Status](https://img.shields.io/travis/glenjamin/pretty-immutable/master.svg)](https://travis-ci.org/glenjamin/pretty-immutable) ![MIT Licensed](https://img.shields.io/npm/l/pretty-immutable.svg)

## Install

```sh
npm install pretty-immutable
```

This library will only work (or really make any sense) if you also have `immutable` installed.

## Usage

```js
var Immutable = require("immutable");
var prettyI = require("pretty-immutable");

var bigMap = Immutable.fromJS({
  a: [1, 2, 3, 4],
  b: {
    blah: {
      blah: [
        {a: 1},
        {b: 2},
        {c: 3}
      ]
    }
  }
});

// Use as a formatter
console.log(prettyI(bigMap)); /*
Map {
  "a": List [ 1, 2, 3, 4 ],
  "b": Map {
    "blah": Map {
      "blah": List [
        Map { "a": 1 },
        Map { "b": 2 },
        Map { "c": 3 }
      ]
    }
  }
}
*/

// Override the built-in inspect() method
prettyI.install(Immutable);

console.log(bigMap.inspect()); /*
Map {
  "a": List [ 1, 2, 3, 4 ],
  "b": Map {
    "blah": Map {
      "blah": List [
        Map { "a": 1 },
        Map { "b": 2 },
        Map { "c": 3 }
      ]
    }
  }
}
*/
```

## License

Copyright 2016 Glen Mailer.

MIT Licensed.

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