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

@creately/array-chunk-by-size

Package Overview
Dependencies
Maintainers
6
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@creately/array-chunk-by-size - npm Package Compare versions

Comparing version 1.0.0 to 1.0.1

4

index.js

@@ -0,1 +1,3 @@

require('fast-text-encoding');
/**

@@ -45,3 +47,3 @@ * Chunk array of objects by their size when stringified into JSON

const str = JSON.stringify(obj);
return Buffer.byteLength(str, 'utf8');
return new TextEncoder().encode(str).length;
} catch (error) {

@@ -48,0 +50,0 @@ return 0;

{
"name": "@creately/array-chunk-by-size",
"version": "1.0.0",
"version": "1.0.1",
"main": "index.js",

@@ -31,3 +31,6 @@ "description": "Chunk array of objects by their size in JSON",

"jest": "24.8.0"
},
"dependencies": {
"fast-text-encoding": "^1.0.0"
}
}
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