Skip to content
This repository has been archived by the owner on Jan 23, 2021. It is now read-only.

Latest commit

 

History

History
44 lines (24 loc) · 1.24 KB

readme.md

File metadata and controls

44 lines (24 loc) · 1.24 KB

Deprecated

Just use Buffer#includes(). It has been available since Node.js 6.


buffer-includes Build Status

Node.js buffer.includes() ponyfill

Install

$ npm install --save buffer-includes

Usage

const bufferIncludes = require('buffer-includes');

bufferIncludes(new Buffer('unicorn'), 'corn');
//=> true

API

bufferIncludes(buffer, needle, byteOffset)

See the buffer.includes() docs for more details.

Related

License

MIT © Sindre Sorhus