# dotspace

> Do vector math in JavaScript.

Latest version **1.4.0** (published 2023-03-08) · MIT license · 0 weekly downloads

## Install

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

## Health

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

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.4.0 |
| Published | 2023-03-08 |
| First published | 2020-12-09 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM |
| Dependencies | 0 |
| Unpacked size | 20.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Joeri Bakker |
| Maintainers | bakkerjoeri |

## Links

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

## Recent versions

- 1.4.0 (latest) — 2023-03-08
- 1.2.0 — 2021-08-03
- 1.1.0 — 2021-03-07
- 1.0.0 — 2020-12-09

## README

# → dotspace

Do vector math in JavaScript.

## Install
This package is [ESM only](https://gist.github.com/sindresorhus/a39789f98801d908bbc7ff3ecc99d99c). Its contents must be `import`ed.

[npm](https://docs.npmjs.com/cli/install):
```
npm install dotspace
```

[yarn](https://yarnpkg.com/cli/add):
```
yarn add dotspace
```

## Usage

When using dotspace all vectors are represented by arrays of numbers:

```ts
const newVector = add([1, 0], [0, 1]); // => [1, 1]
```

This package exports:

* equals
* add
* subtract
* dotProduct
* crossProduct
* magnitude
* resize
* normalize
* multiplyByComponents
* multiplyByScalar
* invert

There are no default exports.

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