# toolsuite

> A JS Toolsuite with many helpfull functions.

Latest version **1.1.1** (published 2018-10-05) · ISC license · 0 weekly downloads

## Install

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

## 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.1.1 |
| Published | 2018-10-05 |
| First published | 2018-09-25 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 10.9 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Maintainers | zeus1309 |
| Keywords | js, javascript, functions, toolkits, e2e |

## Links

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

## Dependencies (1)

- [mocha](https://npm.io/package/mocha.md) ^5.2.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

- 1.1.1 (latest) — 2018-10-05
- 1.1.0 — 2018-10-05
- 1.0.1 — 2018-10-05
- 1.0.0 — 2018-09-25

## README

# toolsuite

A JS Toolsuite with many helpfull functions.

Including e2e tests

```
npm test
```

## functions

You need to import this module with require

```
var toolsuite = require("../toolsuite");
```

### getMinValueFromArray(array)
```
var arr = [9, "test", "1001", 1];

toolsuite.getMinValueFromArray(arr);
```
Result: 1

```
var arr = ["emptyarray", "orstrings];

toolsuite.getMinValueFromArray(arr);
```
Result: null


### getMaxValueFromArray(array)
```
var arr = [9, "test", "1001", 1];

toolsuite.getMaxValueFromArray(arr);
```
Result: 1001

```
var arr = ["emptyarray", "orstrings];

toolsuite.getMaxValueFromArray(arr);
```
Result: null


###getMinValueFromObjectArray(array, key)
```
var arr = [{ key1: 1, key2: 50 }, { key1: 2, key2: 100 }, { key1: 3, key2: -50 }];

toolsuite.getMinValueFromObjectArray(arr, "key2");
```
Result: -50

```
var arr = [{ key1: 1, key2: 50, key3: { subkey: 0 } }, { key1: 2, key2: 100, key3: { subkey: 10 } }, { key1: 3, key2: -50, key3: { subkey: 50 } }];

toolsuite.getMinValueFromObjectArray(arr, "key3.subkey");
```
Result: 0

```
var arr = [{ key1: 1 }, { key1: 2 }];

toolsuite.getMinValueFromObjectArray(arr, "key2");
```
Result: null

```
var arr = [{ key1: 1 }, { key1: 2, key2: 99 }];

toolsuite.getMinValueFromObjectArray(arr, "key2");
```
Result: 99


###getMaxValueFromObjectArray(array, key)
```
var arr = [{ key1: 1, key2: 50 }, { key1: 2, key2: 100 }, { key1: 3, key2: -50 }];

toolsuite.getMaxValueFromObjectArray(arr, "key2");
```
Result: 100

```
var arr = [{ key1: 1, key2: 50, key3: { subkey: 0 } }, { key1: 2, key2: 100, key3: { subkey: 10 } }, { key1: 3, key2: -50, key3: { subkey: 50 } }];

toolsuite.getMaxValueFromObjectArray(arr, "key3.subkey");
```

Result: 50

```
var arr = [{ key1: 1 }, { key1: 2 }];

toolsuite.getMaxValueFromObjectArray(arr, "key2");
```
Result: null

```
var arr = [{ key1: 1 }, { key1: 2, key2: 99 }];

toolsuite.getMaxValueFromObjectArray(arr, "key2");
```
Result: 99

###intBreakDown(number, maxnumber)
```
toolsuite.intBreakDown(360, 360);
```
Result: 0

```
toolsuite.intBreakDown(400, 360);
```

Result: 40

```
toolsuite.intBreakDown(-90, 360);
```
Result: 270

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