mirror of
https://github.com/flynx/diff.js.git
synced 2025-10-29 19:10:11 +00:00
docs...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
8dd3bf064d
commit
e4d6dd9680
15
README.md
15
README.md
@ -1,6 +1,6 @@
|
|||||||
# Object diff
|
# Object diff
|
||||||
|
|
||||||
*Object diff* is a not-so-basic diff/patch/pattern implementation for JavaScript objects / object trees.
|
*Object diff* is a not-so-basic diff/patch/pattern/compare implementation for JavaScript objects / object trees.
|
||||||
|
|
||||||
- [Object diff](#object-diff)
|
- [Object diff](#object-diff)
|
||||||
- [Introduction](#introduction)
|
- [Introduction](#introduction)
|
||||||
@ -361,12 +361,23 @@ Match a string via a nested pattern.
|
|||||||
### Number patterns
|
### Number patterns
|
||||||
|
|
||||||
`NUMBER`
|
`NUMBER`
|
||||||
|
Match any number.
|
||||||
|
|
||||||
`NUMBER(number)`
|
`NUMBER(number)`
|
||||||
|
Match a specific number.
|
||||||
|
|
||||||
`NUMBER(min, max)`
|
`NUMBER(min, max)`
|
||||||
|
Match any number greater or equal to *min* and less than *max*.
|
||||||
|
|
||||||
`NUMBER(min, max, step)`
|
`NUMBER(min, max, step)`
|
||||||
|
Match any number greater or equal to *min* and less than *max* but only if it is a escrete number of *step* away from *min*.
|
||||||
|
Examples: `NUMBER(4, 10, 2)` will match *odd* numbers between 4 and 10, while `NUMBER(1, 10, 2)` will match *even* numbers between 1 and 10.
|
||||||
|
|
||||||
`NUMBER(func)`
|
`NUMBER(func)`
|
||||||
|
Match a number via a function predicate.
|
||||||
|
|
||||||
`NUMBER(pattern)`
|
`NUMBER(pattern)`
|
||||||
Matches a number
|
Match a number via a nested pattern.
|
||||||
|
|
||||||
|
|
||||||
### Array patterns
|
### Array patterns
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user