
Product
Introducing Immutable Scans
Scan results now load faster and remain consistent over time, with stable URLs and on-demand rescans for fresh security data.
Low level bit encoder for buffers
npm install bit-encode
var bits = require('bit-encode')
var buf = Buffer([0])
console.log(bits.get(buf, 0)) // get first bit, returns false (0)
bits.set(buf, 0, true) // set first bit
console.log(bits.get(buf, 0)) // get first bit, returns true (1)
var bool = bits.get(buffer, index)Read the bit at index. A byte in the buffer contains 8 bits so index 0 would return the first bit in the first byte and index 8 would return the first bit in the second byte.
var updated = bits.set(buffer, index, bool)Set the bit at index. Returns true if a bit was updated false otherwise.
MIT
FAQs
Low level bit encoder for buffers
We found that bit-encode demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Product
Scan results now load faster and remain consistent over time, with stable URLs and on-demand rescans for fresh security data.

Product
Socket's new Alert Details page is designed to surface more context, with a clearer layout, reachability dependency chains, and structured review.

Product
Campaign-level threat intelligence in Socket now shows when active supply chain attacks affect your repositories and packages.