44
55## Introduction
66
7- A set of dependency-free JavaScript modules to handle binary data in JS (using
7+ A set of dependency-free JavaScript modules to work with binary data in JS (using
88[ Typed Arrays] ( https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray ) ).
99Includes:
1010
@@ -29,10 +29,10 @@ yarn add @codedread/bitjs
2929
3030### CommonJS/ESM in Node
3131
32- This module is an ES Module, which should work as expected in other projects using ES Modules .
33- However, if you are using CommonJS modules, it's a little trickier to use. One example of this is
34- if a TypeScript project compiles to CommonJS, it will try to turn imports into require() statements,
35- which will break. The fix for this (unfortunately) is to update your tsconfig.json:
32+ This module is an ES Module. If your project uses CommonJS modules, it's a little trickier to use .
33+ One example of this is if a TypeScript project compiles to CommonJS, it will try to turn imports
34+ into require() statements, which will break. The fix for this (unfortunately) is to update your
35+ tsconfig.json:
3636
3737``` json
3838 "moduleResolution" : " Node16" ,
@@ -48,8 +48,8 @@ const { getFullMIMEString } = await import('@codedread/bitjs');
4848
4949### bitjs.archive
5050
51- This package includes objects for decompressing binary data in popular archive formats (zip, rar,
52- tar). Here is a simple example of unrar:
51+ This package includes objects for decompressing and compressing binary data in popular archive
52+ formats (zip, rar, tar). Here is a simple example of unrar:
5353
5454#### Decompressing
5555
@@ -65,7 +65,7 @@ unrar.addEventListener('finish', () => console.log('Done'));
6565unrar .start ();
6666```
6767
68- More explanation and examples are located on [ the API page] ( ./docs/bitjs.archive.md ) .
68+ More details and examples are located on [ the API page] ( ./docs/bitjs.archive.md ) .
6969
7070### bitjs.codecs
7171
@@ -105,8 +105,10 @@ const mimeType = findMimeType(someArrayBuffer);
105105
106106### bitjs.image
107107
108- This package includes code for dealing with binary images. It includes low-level, event-based
109- parsers for GIF, JPEG, and PNG images. It also includes a module for converting WebP images into
108+ This package includes code for dealing with image files. It includes low-level, event-based
109+ parsers for GIF, JPEG, and PNG images.
110+
111+ It also includes a module for converting WebP images into
110112alternative raster graphics formats (PNG/JPG), though this latter module is deprecated, now that
111113WebP images are well-supported in all browsers.
112114
@@ -172,7 +174,7 @@ const crc = bstream.readBits(12); // read in 12 bits as CRC, advancing the point
172174const flagbits = bstream .peekBits (6 ); // look ahead at next 6 bits, but do not advance the pointer
173175```
174176
175- More explanation and examples are located on [ the API page] ( ./docs/bitjs.io.md ) .
177+ More details and examples are located on [ the API page] ( ./docs/bitjs.io.md ) .
176178
177179## Reference
178180
@@ -182,7 +184,6 @@ RAR file format.
182184## History
183185
184186This project grew out of another project of mine, [ kthoom] ( https://github.com/codedread/kthoom ) (a
185- comic book reader implemented in the browser). This repository was automatically exported from
187+ comic book reader implemented in the browser). This repository was automatically exported from
186188[ my original repository on GoogleCode] ( https://code.google.com/p/bitjs ) and has undergone
187- considerable changes and improvements since then, including adding streaming support, starter RarVM
188- support, tests, many bug fixes, and updating the code to modern JavaScript and supported features.
189+ considerable changes and improvements since then.
0 commit comments