Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/parro-it/semver-first-satisfied
Find minimum in an array of version that satisfies a semver range.
https://github.com/parro-it/semver-first-satisfied
Last synced: about 2 months ago
JSON representation
Find minimum in an array of version that satisfies a semver range.
- Host: GitHub
- URL: https://github.com/parro-it/semver-first-satisfied
- Owner: parro-it
- License: mit
- Created: 2016-01-21T22:05:45.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2016-01-29T14:00:49.000Z (over 8 years ago)
- Last Synced: 2024-04-15T00:06:09.997Z (2 months ago)
- Language: JavaScript
- Homepage:
- Size: 5.86 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- License: license
Lists
- awesome-micro-npm-packages - semver-first-satisfied - Find minimum in an array of version that satisfies a semver range. (Modules / Semver)
- awesome-micro-npm-packages - semver-first-satisfied - Find minimum in an array of version that satisfies a semver range. (Modules / Semver)
README
# semver-first-satisfied
> Find minimum in an array of version that satisfies a semver range.
> Return the version string or null if no version in the arrya satisfy given range.
[![Travis Build Status](https://img.shields.io/travis/parro-it/semver-first-satisfied.svg)](http://travis-ci.org/parro-it/semver-first-satisfied)
[![NPM module](https://img.shields.io/npm/v/semver-first-satisfied.svg)](https://npmjs.org/package/semver-first-satisfied)
[![NPM downloads](https://img.shields.io/npm/dt/semver-first-satisfied.svg)](https://npmjs.org/package/semver-first-satisfied)## Installation
```bash
npm install --save semver-first-satisfied
```## Usage
```javascript
const firstSatisfied = require('semver-first-satisfied');
console.log(firstSatisfied('^1.1.0', ['0.5.0', '1.1.4', '1.2.3', '1.1.1']));
```
> '1.1.1'## License
The MIT License (MIT)
Copyright (c) 2015 parro-it