byte
byte copied to clipboard
Input Buffer and Output Buffer, just like Java ByteBuffer
BTW: js CESU-8 encoding is faster then Buffer UTF-8 encoding ``` putRawStringSmallLessThan0x80*10000: 672.642ms putRawStringSmallLessThan0x800*10000: 592.960ms putRawStringSmallBiggerThan0x800*10000: 861.010ms putUTF8RawStringSmallLessThan0x80*10000: 841.638ms putUTF8RawStringSmallLessThan0x800*10000: 958.383ms putUTF8RawStringSmallBiggerThan0x800*10000: 1793.470ms ```
```js console.time('byte'); require('byte'); console.timeEnd('byte'); ``` 优化前 ```bash byte: 55.795ms ``` 优化后 ```bash byte: 3.092ms ```
Currently, `_size` and `_limit` is incorrect when `options.array` passed in constructor unless you set it explicitly. This PR will auto set it according to the `length` of `options.array`.
This PR contains the following updates: | Package | Change | [Age](https://docs.renovatebot.com/merge-confidence/) | [Confidence](https://docs.renovatebot.com/merge-confidence/) | |---|---|---|---| | [utility](https://redirect.github.com/node-modules/utility) | [`^1.13.1` → `^2.0.0`](https://renovatebot.com/diffs/npm/utility/1.18.0/2.5.0) |  |  | --- ### Release...
This PR contains the following updates: | Package | Change | [Age](https://docs.renovatebot.com/merge-confidence/) | [Confidence](https://docs.renovatebot.com/merge-confidence/) | |---|---|---|---| | [long](https://redirect.github.com/dcodeIO/long.js) | [`^4.0.0` → `^5.0.0`](https://renovatebot.com/diffs/npm/long/4.0.0/5.3.2) |  |  | --- ### Release...
This PR contains the following updates: | Package | Change | [Age](https://docs.renovatebot.com/merge-confidence/) | [Confidence](https://docs.renovatebot.com/merge-confidence/) | |---|---|---|---| | [eslint-config-egg](https://redirect.github.com/eggjs/eslint-config-egg) | [`^7.0.0` → `^14.0.0`](https://renovatebot.com/diffs/npm/eslint-config-egg/7.5.1/14.1.0) |  |  | --- ### Release...
This PR contains the following updates: | Package | Change | [Age](https://docs.renovatebot.com/merge-confidence/) | [Confidence](https://docs.renovatebot.com/merge-confidence/) | |---|---|---|---| | [egg-ci](https://redirect.github.com/eggjs/egg-ci) | [`^1.8.0` → `^2.0.0`](https://renovatebot.com/diffs/npm/egg-ci/1.19.1/2.2.0) |  |  | --- ### Release...
This PR contains the following updates: | Package | Change | [Age](https://docs.renovatebot.com/merge-confidence/) | [Confidence](https://docs.renovatebot.com/merge-confidence/) | |---|---|---|---| | [debug](https://redirect.github.com/debug-js/debug) | [`^3.1.0` → `^4.0.0`](https://renovatebot.com/diffs/npm/debug/3.2.7/4.4.3) |  |  | --- ### Release...