File: README.markdown

package info (click to toggle)
node-vinyl-fs 3.0.3-5
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, sid
  • size: 1,884 kB
  • sloc: makefile: 43; sh: 43
file content (62 lines) | stat: -rw-r--r-- 855 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
buffer-equal
============

Return whether two buffers are equal.

[![build status](https://secure.travis-ci.org/substack/node-buffer-equal.png)](http://travis-ci.org/substack/node-buffer-equal)

example
=======

``` js
var bufferEqual = require('buffer-equal');

console.dir(bufferEqual(
    new Buffer([253,254,255]),
    new Buffer([253,254,255])
));
console.dir(bufferEqual(
    new Buffer('abc'),
    new Buffer('abcd')
));
console.dir(bufferEqual(
    new Buffer('abc'),
    'abc'
));
```

output:

```
true
false
undefined
```

methods
=======

``` js
var bufferEqual = require('buffer-equal')
```

bufferEqual(a, b)
-----------------

Return whether the two buffers `a` and `b` are equal.

If `a` or `b` is not a buffer, return `undefined`.

install
=======

With [npm](http://npmjs.org) do:

```
npm install buffer-equal
```

license
=======

MIT