# mini-semver

> Fast semantic version parser based on node-semver

Latest version **0.1.1** (published 2019-04-08) · ISC license · 0 weekly downloads

## Install

```sh
npm install mini-semver
pnpm add mini-semver
yarn add mini-semver
bun add mini-semver
```

Provides the command `mini-semver`.

## Health

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

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

Warnings: low downloads; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.1 |
| Published | 2019-04-08 |
| First published | 2019-04-07 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 2 |
| Unpacked size | 21.5 KB |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 2 |
| Maintainers | ajaxlab |
| Keywords | semver |

## Links

- npm: https://www.npmjs.com/package/mini-semver
- Repository: https://github.com/ajaxlab/mini-semver
- Issues: https://github.com/ajaxlab/mini-semver/issues
- npm.io page: https://npm.io/package/mini-semver

## Dependencies (2)

- [semver](https://npm.io/package/semver.md) 6.0.0
- [@types/semver](https://npm.io/package/@types/semver.md) 6.0.0

## Recent versions

- 0.1.1 (latest) — 2019-04-08
- 0.1.0 — 2019-04-07

## README

# mini-semver

Fast semantic version parser ([node-semver](https://github.com/npm/node-semver) wrapper)

## Motive

For most node package dependencies, the simple caret ranges are most frequently used. Mini-semver enhances semver.satisfy method for the simple caret ranges (such as ^[num].[num].[num]).

## Install

```bash
npm install --save mini-semver
````

```bash
yarn add mini-semver
````

## Module

```js
import miniSemver from 'mini-semver';
```

```js
const miniSemver = require('mini-semver');
```

## Usage

Please refer to https://github.com/npm/node-semver#usage

## cli

```
$ mini-semver -h
```

## Test

This test cases are from [node-semver](https://github.com/npm/node-semver)

```bash
node ./test
```

```bash
npm run test
```

## Performance

* Test for semver.satisfies() with the simple caret ranges such as ^[num].[num].[num]

  ```
  $ ts-node ./performance/mini-semver.ts
  $ ts-node ./performance/semver.ts
  ```

  | mini-semver | semver |
  |:--------|:--------:|
  | 36ms ~ 39ms | 198ms ~ 217ms |

## License

```
The ISC License

Copyright (c) Isaac Z. Schlueter, Ajaxlab and Contributors

Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted, provided that the above
copyright notice and this permission notice appear in all copies.

THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR
IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.

```

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