From e7d9dbe3764e3896a4ef39ac66ef74d5023a6671 Mon Sep 17 00:00:00 2001 From: Vincent Weevers Date: Sat, 17 Apr 2021 12:58:36 +0200 Subject: [PATCH] 5.0.0 --- CHANGELOG.md | 24 ++++++++++++++++++++++++ UPGRADING.md | 33 +++++++++++++++++++++++++++++---- package.json | 2 +- 3 files changed, 54 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 100aa43d..8e2e3b1a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,28 @@ _**If you are upgrading:** please see [`UPGRADING.md`](UPGRADING.md)._ +## [5.0.0] - 2021-04-17 + +### Changed + +- **Breaking:** modernize syntax and bump `standard` ([Level/community#98](https://github.com/Level/community/issues/98)) ([`e19cd54`](https://github.com/Level/levelup/commit/e19cd54), [`762d989`](https://github.com/Level/levelup/commit/762d989)) (Vincent Weevers) +- **Breaking:** remove `Batch._levelup` property ([`cfce6bb`](https://github.com/Level/levelup/commit/cfce6bb)) (Vincent Weevers). +- Align `nextTick` behavior with `abstract-leveldown` ([`4b35716`](https://github.com/Level/levelup/commit/4b35716)) (Vincent Weevers). +- Add `files` to package.json and remove `.npmignore` ([`29d8b5d`](https://github.com/Level/levelup/commit/29d8b5d)) (Vincent Weevers) +- Replace `xtend` with `Object.assign()` ([`7bfc0d4`](https://github.com/Level/levelup/commit/7bfc0d4)) (Vincent Weevers) +- Bump `deferred-leveldown`, `level-errors`, `-iterator-stream` and `-supports` ([`8b518b1`](https://github.com/Level/levelup/commit/8b518b1), [`1b0cfb8`](https://github.com/Level/levelup/commit/1b0cfb8)) (Vincent Weevers) +- Refactor `promisify()` code by using `catering` module ([#700](https://github.com/Level/levelup/issues/700)) (Lars-Magnus Skog) + +### Added + +- Support encoding options on chained batch `put()` and `del()` ([#717](https://github.com/Level/levelup/issues/717), [#633](https://github.com/Level/levelup/issues/633)) ([`0765808`](https://github.com/Level/levelup/commit/0765808)) (Vincent Weevers) + +### Removed + +- **Breaking:** drop node 6, 8, IE, Safari 9-11 & stock Android ([Level/community#98](https://github.com/Level/community/issues/98)) ([`bb1d4da`](https://github.com/Level/levelup/commit/bb1d4da)) (Vincent Weevers). +- Remove legacy range options from readme and tests ([Level/community#86](https://github.com/Level/community/issues/86)) ([`2df2a44`](https://github.com/Level/levelup/commit/2df2a44)) (Vincent Weevers) +- Remove default export ([Level/community#87](https://github.com/Level/community/issues/87)) ([`3fd21e2`](https://github.com/Level/levelup/commit/3fd21e2)) (Vincent Weevers) + ## [4.4.0] - 2020-04-11 ### Changed @@ -1107,6 +1129,8 @@ _**If you are upgrading:** please see [`UPGRADING.md`](UPGRADING.md)._ - Remove unused `inherits` variable ([**@rvagg**](https://github.com/rvagg)) +[5.0.0]: https://github.com/Level/levelup/compare/v4.4.0...v5.0.0 + [4.4.0]: https://github.com/Level/levelup/compare/v4.3.2...v4.4.0 [4.3.2]: https://github.com/Level/levelup/compare/v4.3.1...v4.3.2 diff --git a/UPGRADING.md b/UPGRADING.md index a3754c1f..9a27052f 100644 --- a/UPGRADING.md +++ b/UPGRADING.md @@ -2,18 +2,43 @@ This document describes breaking changes and how to upgrade. For a complete list of changes including minor and patch releases, please refer to the [changelog](CHANGELOG.md). -## v4 +## 5.0.0 -There have been two major updates to dependencies. First, `level-iterator-stream` is now based on [`readable-stream@3`](https://github.com/nodejs/readable-stream#version-3xx). Second, `deferred-leveldown` is now based on [`abstract-leveldown@6`](https://github.com/Level/abstract-leveldown/blob/master/UPGRADING.md#v6). Please follow these links for more information; both contain significant enough changes to warrant this `levelup` major. In addition, all aforementioned dependencies and by extension `levelup` have dropped support of IE10. +Legacy range options have been removed ([Level/community#86](https://github.com/Level/community/issues/86)). If you previously did: + +```js +db.createReadStream({ start: 'a', end: 'z' }) +``` + +An error would now be thrown and you must instead do: + +```js +db.createReadStream({ gte: 'a', lte: 'z' }) +``` + +The same applies to `db.iterator()`, `db.createKeyStream()` and `db.createValueStream()`. + +This release also drops support of legacy runtime environments ([Level/community#98](https://github.com/Level/community/issues/98)): + +- Node.js 6 and 8 +- Internet Explorer 11 +- Safari 9-11 +- Stock Android browser (AOSP). + +Lastly, in browsers, `process.nextTick()` has been replaced with [`queue-microtask`](https://github.com/feross/queue-microtask), except in streams. In the future we might use `queueMicrotask()` in Node.js too. + +## 4.0.0 + +There have been two major updates to dependencies. First, `level-iterator-stream` is now based on [`readable-stream@3`](https://github.com/nodejs/readable-stream#version-3xx). Second, `deferred-leveldown` is now based on [`abstract-leveldown@6`](https://github.com/Level/abstract-leveldown/blob/master/UPGRADING.md#v6). Please follow these links for more information; both contain significant enough changes to warrant this `levelup` major. In addition, all aforementioned dependencies and by extension `levelup` have dropped support of IE10. To get a consistent behavior between opening and opened `levelup` instances (in the former case, your store will be wrapped with `deferred-leveldown`), we recommend to pair `levelup@4` only with a store based on `abstract-leveldown` >= 6. For example, `deferred-leveldown` now rejects `null` and `undefined` values. If you pair `levelup@4` with an older store, `db.put('key', null)` would only throw an error if `db` is still opening itself. -## v3 +## 3.0.0 1. Dropped support for node 4. 2. Batch operations no longer default to `'put'`. If `type` isn't specified, an error will be thrown, courtesy of `abstract-leveldown`. -## v2 +## 2.0.0 ### Summary diff --git a/package.json b/package.json index e4d55f6a..a7596888 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "levelup", - "version": "4.4.0", + "version": "5.0.0", "description": "Fast & simple storage - a Node.js-style LevelDB wrapper", "license": "MIT", "main": "lib/levelup.js",