fast-boolean-array 1.4.5 → 1.4.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # Fast Boolean Array
1
+ # Fast Boolean Array ![Build](https://github.com/UltraCakeBakery/FastBooleanArray/actions/workflows/ci.yml/badge.svg?event=push)
2
2
 
3
3
  In JavaScript, when working with large arrays of boolean values, a common challenge is efficiently indexing and retrieving these values. Using a regular JavaScript array to store booleans is straightforward, but it is memory-inefficient. While booleans are conceptually 1-bit values, JavaScript engines, like V8 (in Chrome and Node.js), allocate 1 byte (8 bits) per boolean for optimization purposes. This can waste a significant amount of memory when dealing with large arrays.
4
4
 
@@ -8,17 +8,18 @@ For detailed benchmark results, see below.
8
8
 
9
9
  ## Features
10
10
 
11
-
12
11
  - **Memory Efficiency**: Stores booleans in bits rather than bytes, drastically reducing memory usage.
13
12
  - **Fast Set Performance**: Up to 10x faster sets for fast data re-mapping.
14
- - **Familiar API**: `Map` and `Set` like API for minimal learning curve. Intuitive helper functions, and works in `for.. of`.
15
- - **Array like interface**: call `.accessLikeArray()` to access it like an array`someArray[index]` (beware of the performance penalty caused by the Proxy)!
13
+ - **Familiar API**: `Map` and `Set` like API for minimal learning curve. Intuitive helper functions, and works in `for.. of`.
14
+ - **Array like interface**: call `.accessLikeArray()` to access it like an array`someArray[index]` (beware of the performance penalty caused by the Proxy)!
15
+
16
16
  ---
17
17
 
18
18
  ## Why Use Fast Boolean Array?
19
19
 
20
20
  - **Easy to Use**: Familiar `Map` and `Set` like API for minimal learning curve.
21
21
  - **Scalable**: Suitable for high-performance, memory-sensitive projects.
22
+
22
23
  ---
23
24
 
24
25
  ## Installation
@@ -37,7 +38,7 @@ pnpm install fast-boolean-array --save-dev
37
38
  Here's how to use the Fast Boolean Array:
38
39
 
39
40
  ```javascript
40
- import BooleanArray from 'fast-boolean-array';
41
+ import BooleanArray from "fast-boolean-array";
41
42
  // const BooleanArray = require('fast-boolean-array'); commonjs works too.
42
43
 
43
44
  // Create a new BooleanArray with the desired size
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fast-boolean-array",
3
- "version": "1.4.5",
3
+ "version": "1.4.6",
4
4
  "homepage": "https://github.com/UltraCakeBakery/FastBooleanArray",
5
5
  "repository": {
6
6
  "type": "git",
@@ -25,9 +25,8 @@
25
25
  }
26
26
  },
27
27
  "scripts": {
28
- "check": "npm run check:types ; npm run check:test",
29
- "check:test": "vitest",
30
- "check:types": "npx --yes @arethetypeswrong/cli --pack .",
28
+ "test": "vitest",
29
+ "check-types": "npx --yes @arethetypeswrong/cli --pack .",
31
30
  "build": "tsup src/index.ts --dts --format cjs,esm --clean --sourcemap --minify",
32
31
  "publish": "npm publish"
33
32
  },
@@ -1,11 +0,0 @@
1
- # To get started with Dependabot version updates, you'll need to specify which
2
- # package ecosystems to update and where the package manifests are located.
3
- # Please see the documentation for all configuration options:
4
- # https://docs.github.com/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file
5
-
6
- version: 2
7
- updates:
8
- - package-ecosystem: "npm" # See documentation for possible values
9
- directory: "/" # Location of package manifests
10
- schedule:
11
- interval: "weekly"