Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

buffer-to-uint8array

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

buffer-to-uint8array - npm Package Compare versions

Comparing version 1.0.0 to 1.1.0

test/u8.js

5

index.js
module.exports = function (buf) {
if (!buf) return undefined;
if (buf.constructor.name === 'Uint8Array'
|| buf.constructor === Uint8Array) {
return buf;
}
if (typeof buf === 'string') buf = Buffer(buf);

@@ -3,0 +8,0 @@ var a = new Uint8Array(buf.length);

2

package.json
{
"name": "buffer-to-uint8array",
"version": "1.0.0",
"version": "1.1.0",
"description": "convert a buffer (or string) to a Uint8Array",

@@ -5,0 +5,0 @@ "main": "index.js",

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc