Skip to content

Commit 946a57f

Browse files
authored
Breaking: upgrade to abstract-level 3 (#17)
Ref: https://github.com/Level/abstract-level/blob/v3.0.0/UPGRADING.md Category: change
1 parent a2fd936 commit 946a57f

File tree

8 files changed

+43
-148
lines changed

8 files changed

+43
-148
lines changed

.airtap.yml

+8-17
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,13 @@
11
providers:
2-
- airtap-sauce
2+
- airtap-playwright
33

44
browsers:
5-
- name: chrome
5+
- name: chromium
66
- name: firefox
7-
- name: safari
8-
version: 12..latest
9-
- name: ios_saf
10-
version: 12..latest
11-
- name: chrome for android
12-
version: 6..latest
13-
- name: msedge
7+
- name: webkit
148

15-
presets:
16-
local:
17-
providers:
18-
- airtap-playwright
19-
browsers:
20-
- name: chromium
21-
- name: firefox
22-
- name: webkit
9+
# Until airtap switches to rollup
10+
browserify:
11+
- transform: babelify
12+
global: true
13+
presets: ["@babel/preset-env"]

.github/dependabot.yml

+5
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@ updates:
77
ignore:
88
- dependency-name: standard
99
- dependency-name: ts-standard
10+
- dependency-name: voxpelli/tsconfig
11+
- dependency-name: typescript
12+
- dependency-name: hallmark
13+
- dependency-name: "@babel/preset-env"
14+
- dependency-name: babelify
1015
- package-ecosystem: github-actions
1116
directory: /
1217
schedule:

.github/workflows/sauce.yml

-33
This file was deleted.

.github/workflows/test.yml

+20-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ on: [push, pull_request]
33
permissions:
44
contents: read
55
jobs:
6-
test:
6+
node:
77
runs-on: ubuntu-latest
88
strategy:
99
matrix:
@@ -26,3 +26,22 @@ jobs:
2626
uses: codecov/codecov-action@v3
2727
with:
2828
file: coverage/lcov.info
29+
browsers:
30+
name: Browsers
31+
if: ${{ github.actor != 'dependabot[bot]' }}
32+
runs-on: ubuntu-latest
33+
steps:
34+
- name: Checkout
35+
uses: actions/checkout@v4
36+
- name: Set up node
37+
uses: actions/setup-node@v4
38+
with:
39+
node-version: lts/*
40+
- name: Install
41+
run: npm install --ignore-scripts
42+
- name: Install Playwright dependencies
43+
run: npx --no-install playwright install-deps
44+
- name: Install Playwright
45+
run: npx --no-install playwright install
46+
- name: Test
47+
run: npm run test-browsers

README.md

+1-11
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
**In-memory [`abstract-level`][abstract-level] database for Node.js and browsers, backed by a [fully persistent red-black tree](https://www.npmjs.com/package/functional-red-black-tree).** The successor to [`memdown`](https://github.com/Level/memdown) and [`level-mem`](https://github.com/Level/mem).
44

5-
> :pushpin: Which module should I use? What is `abstract-level`? Head over to the [FAQ](https://github.com/Level/community#faq).
5+
> :pushpin: Wondering what happened to `levelup`? Visit [Frequently Asked Questions](https://github.com/Level/community#faq).
66
77
[![level badge][level-badge]](https://github.com/Level/awesome)
88
[![npm](https://img.shields.io/npm/v/memory-level.svg)](https://www.npmjs.com/package/memory-level)
@@ -38,10 +38,6 @@ for await (const [key, value] of db.iterator({ gt: 'a' })) {
3838
}
3939
```
4040

41-
<!-- ## Browser support
42-
43-
[![Sauce Test Status](https://app.saucelabs.com/browser-matrix/level-ci.svg)](https://app.saucelabs.com/u/level-ci) -->
44-
4541
## API
4642

4743
The API of `memory-level` follows that of [`abstract-level`](https://github.com/Level/abstract-level) with a one additional constructor option (see below). The `createIfMissing` and `errorIfExists` options of `abstract-level` are not relevant here. Data is discarded when the last reference to the database is released (i.e. `db = null`). Closing or reopening the database has no effect on the data. Data is _not_ copied: when storing a Buffer value for example, subsequent mutations to that Buffer will affect the stored data too.
@@ -68,12 +64,6 @@ npm install memory-level
6864
6965
See the [Contribution Guide](https://github.com/Level/community/blob/master/CONTRIBUTING.md) for more details.
7066

71-
<!-- ## Big Thanks
72-
73-
Cross-browser Testing Platform and Open Source ♥ Provided by [Sauce Labs](https://saucelabs.com).
74-
75-
[![Sauce Labs logo](./sauce-labs.svg)](https://saucelabs.com) -->
76-
7767
## License
7868

7969
[MIT](LICENSE)

UPGRADING.md

+4
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
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).
44

5+
## 3.0.0
6+
7+
This release upgrades to `abstract-level` 3. Please see its [upgrade guide](https://github.com/Level/abstract-level/blob/v3.0.0/UPGRADING.md) (note that `memory-level` already dropped Node.js 16).
8+
59
## 2.0.0
610

711
This release upgrades to `abstract-level` 2.0.0 which adds [hooks](https://github.com/Level/abstract-level#hooks) and drops callbacks, not-found errors and support of Node.js < 16. Please refer to the [upgrade guide of `abstract-level`](https://github.com/Level/abstract-level/blob/v2.0.0/UPGRADING.md). The only thing to add is that `memory-level` also drops Node.js 16.

package.json

+5-5
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,7 @@
99
"scripts": {
1010
"test": "standard && hallmark && (nyc -s node test.js | tap-arc) && nyc report",
1111
"test-pessimistic": "node test.js | tap-arc -pv",
12-
"test-browsers": "airtap --coverage --verbose test.js",
13-
"test-browsers-local": "airtap --coverage -p local test.js",
12+
"test-browsers": "airtap --coverage test.js",
1413
"coverage": "nyc report -r lcovonly"
1514
},
1615
"files": [
@@ -20,15 +19,16 @@
2019
"CHANGELOG.md"
2120
],
2221
"dependencies": {
23-
"abstract-level": "^2.0.1",
22+
"abstract-level": "^3.0.0",
2423
"functional-red-black-tree": "^1.0.1",
2524
"module-error": "^1.0.1"
2625
},
2726
"devDependencies": {
27+
"@babel/preset-env": "^7.26.0",
2828
"@voxpelli/tsconfig": "^15.0.0",
29-
"airtap": "^4.0.3",
29+
"airtap": "^5.0.0",
3030
"airtap-playwright": "^1.0.1",
31-
"airtap-sauce": "^1.1.0",
31+
"babelify": "^10.0.0",
3232
"buffer": "^6.0.3",
3333
"hallmark": "^5.0.1",
3434
"nyc": "^17.1.0",

sauce-labs.svg

-81
This file was deleted.

0 commit comments

Comments
 (0)