From 99f133ea3969664b64950c7615031351950469a4 Mon Sep 17 00:00:00 2001 From: Rodrigo Fernandes Date: Sun, 9 Apr 2017 16:22:16 +0100 Subject: [PATCH] Add range and comparator intersection docs to README --- README.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/README.md b/README.md index 792ce53c..300066f3 100644 --- a/README.md +++ b/README.md @@ -329,6 +329,10 @@ strings that they parse. (`major`, `premajor`, `minor`, `preminor`, `patch`, `prepatch`, or `prerelease`), or null if the versions are the same. +### Comparators +* `intersects(comparator)`: Return true if the comparators intersect +* `satisfiesRange(range)`: Return true if the comparator intersects with any +of the range's comparators ### Ranges @@ -347,6 +351,7 @@ strings that they parse. the bounds of the range in either the high or low direction. The `hilo` argument must be either the string `'>'` or `'<'`. (This is the function called by `gtr` and `ltr`.) +* `intersects(range)`: Return true if any of the ranges comparators intersect Note that, since ranges may be non-contiguous, a version might not be greater than a range, less than a range, *or* satisfy a range! For