# karmia-utility-object

> Karmia object utility module.

Latest version **0.5.0** (published 2020-12-12) · MIT license · 0 weekly downloads

> **Deprecated.** This package is deprecated.

## Install

```sh
npm install karmia-utility-object
pnpm add karmia-utility-object
yarn add karmia-utility-object
bun add karmia-utility-object
```

## Health

**Score 10/100 (F)** — status: deprecated.

Negative: deprecated.

## Facts

| | |
|---|---|
| Version | 0.5.0 |
| Published | 2020-12-12 |
| First published | 2017-01-17 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >=8.0.0 |
| Dependencies | 1 |
| Unpacked size | 16.7 KB |
| Known vulnerabilities | 0 |
| Install scripts | yes |
| GitHub stars | 0 |
| Author | Kazuma Fujimaki |
| Maintainers | fujimaki-k |

## Links

- npm: https://www.npmjs.com/package/karmia-utility-object
- Repository: https://github.com/fujimakishouten/karmia-utility-object
- Issues: https://github.com/fujimakishouten/karmia-utility-object/issues
- npm.io page: https://npm.io/package/karmia-utility-object

## Dependencies (1)

- [typescript](https://npm.io/package/typescript.md) ^4.1.3

## Recent versions

- 0.5.0 (latest) — 2020-12-12
- 0.4.1 — 2018-06-18
- 0.4.0 — 2018-06-18
- 0.3.4 — 2018-04-10
- 0.3.3 — 2018-04-10
- 0.3.2 — 2018-04-10
- 0.3.1 — 2018-04-06
- 0.3.0 — 2018-04-06
- 0.2.1 — 2018-04-04
- 0.2.0 — 2018-04-03
- 0.1.4 — 2018-04-03
- 0.1.3 — 2018-04-02
- 0.1.2 — 2017-06-07
- 0.1.1 — 2017-02-06
- 0.1.0 — 2017-01-17

## README

# karmia-utility-object
Karmia utility object module

## Usage
```javascript
const karmia_utility_object = require('karmia-utility-object').default,
    kobject = new karmia_utility_object();
```

### isObject
- value ```<*>```

Check if value is an instance of Object


### isPlainObject
- value ```<*>```

Check if value is a plain object


### flip
- object ```<Object>```

Get object that exchanges key with their value

```javascript
kobject.flip({a: 'A', b: 'B', c: 'C', d: 1, e: 2, f: 3});
// => {A: 'a', B: 'b', C: 'c', 1: d, 2: e, 3: f}
```

### mergeProperties
- object1 ```<Object>```
- object2 ```<Object>```

```javascript
const object1 = {
        a: {
            b: 'b',
            c: {
                d: 'd'
            }
        }
    },
    object2 = {
        a: {
            c: {
                e: 'e'
            },
            f: 'f'
        }
    };

kobject.mergeProperties(object1, object2);
// => {a: {b: 'b', c: {d: 'd', e: 'e'}, f: 'f'}}
```

### removeProperty
- object ```<Object>```
- property ```<Array|string>```

```javascript
const object = {
    a: 'a',
    b: {
        c: 'c'
        d: {
            e: 'e'
        }
    }
};

kobject.removeProperty(object, ['a', 'd']);
// => {b: {c: 'c'}}
```

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