# sum.js

> Sum a list of number literals, nested object property values, or values returned from a custom function for Node.js and the browser.

Latest version **0.6.0** (published 2014-11-14) · MIT license · 0 weekly downloads

## Install

```sh
npm install sum.js
pnpm add sum.js
yarn add sum.js
bun add sum.js
```

## Health

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

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.6.0 |
| Published | 2014-11-14 |
| First published | 2013-12-13 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Wil Moore III |
| Maintainers | wilmoore |
| Keywords | sum, array, math, addition, fold, reduce |

## Links

- npm: https://www.npmjs.com/package/sum.js
- Repository: https://github.com/wilmoore/sum.js
- Issues: https://github.com/wilmoore/sum.js/issues
- npm.io page: https://npm.io/package/sum.js

## Dependencies (1)

- [selectn](https://npm.io/package/selectn.md) ~0.9.6

## Alternatives

- [random-seedable](https://npm.io/package/random-seedable.md) — 27.9K weekly downloads
- [n2words](https://npm.io/package/n2words.md) — 22.2K weekly downloads
- [@stdlib/math-base-special-factorialln](https://npm.io/package/@stdlib/math-base-special-factorialln.md) — 5.7K weekly downloads
- [@stdlib/math-base-special-abs2](https://npm.io/package/@stdlib/math-base-special-abs2.md) — 1.7K weekly downloads
- [commons-math-interpolation](https://npm.io/package/commons-math-interpolation.md) — 1.4K weekly downloads

## Recent versions

- 0.6.0 (latest) — 2014-11-14
- 0.5.0 — 2013-12-15
- 0.4.0 — 2013-12-15
- 0.3.0 — 2013-12-15
- 0.2.0 — 2013-12-15
- 0.1.0 — 2013-12-13

## README

# sum.js

[![Build Status](http://img.shields.io/travis/wilmoore/sum.js.svg)](https://travis-ci.org/wilmoore/sum.js) [![NPM version](http://img.shields.io/npm/v/sum.js.svg)](https://www.npmjs.org/package/sum.js) [![NPM downloads](http://img.shields.io/npm/dm/sum.js.svg)](https://www.npmjs.org/package/sum.js) [![LICENSE](http://img.shields.io/npm/l/sum.js.svg)](license)

> Sum a list of number literals, nested object property values, or values returned from a custom function for [Node.js][] and the browser.

## Examples

#### Number literals

    sum([1, 2, 3, 4]);
    //=> 10

#### Nested object properties

    var strings = ['literal', 'constructor'];
    sum(strings, 'length');
    //=> 18

#### Custom function

    sum([1, 2, 3, 4], function (n) { n * 60 });
    //=> 600

## Installation

[component](http://component.io/wilmoore/sum.js)

    $ component install wilmoore/sum.js

[bower](http://sindresorhus.com/bower-components/)

    $ bower install sum.js

[npm](https://npmjs.org/package/sum.js)

[![NPM](https://nodei.co/npm/sum.js.png?downloads=true)](https://nodei.co/npm/sum.js/)

[volo](http://volojs.org)

    $ volo add wilmoore/sum.js

[manual][]

1. download

        % curl -#O https://raw.github.com/wilmoore/sum.js/master/sum.min.js
        or
        % curl -#O https://raw.github.com/wilmoore/sum.js/master/sum.js

2. use

        <script src="sum.min.js"></script>
        or
        <script src="sum.js"></script>

## License

  [MIT](license)

[Node.js]:  http://nodejs.org
[manual]:   http://yuiblog.com/blog/2006/06/01/global-domination/

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