indexeddbshim 10.1.0 → 11.0.0
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/badges/licenses-badge-dev.svg +1 -1
- package/badges/licenses-badge.svg +1 -1
- package/dist/indexeddbshim-Key.js +35 -32
- package/dist/indexeddbshim-Key.js.map +1 -1
- package/dist/indexeddbshim-Key.min.js +2 -2
- package/dist/indexeddbshim-Key.min.js.map +1 -1
- package/dist/{indexeddbshim-UnicodeIdentifiers-node.js → indexeddbshim-UnicodeIdentifiers-node.cjs} +123 -53
- package/dist/indexeddbshim-UnicodeIdentifiers-node.cjs.map +1 -0
- package/dist/indexeddbshim-UnicodeIdentifiers.js +227 -194
- package/dist/indexeddbshim-UnicodeIdentifiers.js.map +1 -1
- package/dist/indexeddbshim-UnicodeIdentifiers.min.js +2 -8
- package/dist/indexeddbshim-UnicodeIdentifiers.min.js.map +1 -1
- package/dist/{indexeddbshim-node.js → indexeddbshim-node.cjs} +121 -51
- package/dist/indexeddbshim-node.cjs.map +1 -0
- package/dist/indexeddbshim-noninvasive.js +225 -192
- package/dist/indexeddbshim-noninvasive.js.map +1 -1
- package/dist/indexeddbshim-noninvasive.min.js +2 -8
- package/dist/indexeddbshim-noninvasive.min.js.map +1 -1
- package/dist/indexeddbshim.js +225 -192
- package/dist/indexeddbshim.js.map +1 -1
- package/dist/indexeddbshim.min.js +2 -8
- package/dist/indexeddbshim.min.js.map +1 -1
- package/package.json +62 -48
- package/src/IDBTransaction.js +1 -0
- package/src/node-UnicodeIdentifiers.js +2 -3
- package/src/node.js +2 -3
- package/dist/indexeddbshim-UnicodeIdentifiers-node.js.map +0 -1
- package/dist/indexeddbshim-node.js.map +0 -1
package/package.json
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "indexeddbshim",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "11.0.0",
|
|
4
|
+
"type": "module",
|
|
4
5
|
"author": "Parashuram <code@nparashuram.com>",
|
|
5
6
|
"contributors": [
|
|
6
7
|
"Brett Zamir"
|
|
@@ -8,17 +9,20 @@
|
|
|
8
9
|
"license": "(MIT OR Apache-2.0)",
|
|
9
10
|
"homepage": "https://github.com/indexeddbshim/IndexedDBShim",
|
|
10
11
|
"description": "A polyfill for IndexedDB using WebSql",
|
|
11
|
-
"
|
|
12
|
+
"c8": {
|
|
12
13
|
"reporter": [
|
|
13
14
|
"text",
|
|
14
15
|
"json-summary",
|
|
15
16
|
"lcov"
|
|
16
17
|
],
|
|
17
18
|
"exclude": [
|
|
19
|
+
"node_modules/**",
|
|
20
|
+
"IndexedDBShim/node_modules/**",
|
|
18
21
|
"web-platform-tests/**",
|
|
19
22
|
"coverage",
|
|
20
23
|
"ignore",
|
|
21
24
|
".eslintrc.js",
|
|
25
|
+
".mocharc.cjs",
|
|
22
26
|
"tests-mocha/**",
|
|
23
27
|
"tests-polyfill/**",
|
|
24
28
|
"test-support/**"
|
|
@@ -51,16 +55,16 @@
|
|
|
51
55
|
"w3c-old": "run-s clean-w3cOld coverage:w3cOld clean-w3cOld",
|
|
52
56
|
"tests-polyfill": "run-s clean-polyfill coverage:fake coverage:mock coverage:w3cOld",
|
|
53
57
|
"mocha": "run-s clean-mocha coverage:mocha clean-mocha",
|
|
54
|
-
"rollup": "rollup -c
|
|
55
|
-
"coverage:fake": "
|
|
56
|
-
"coverage:mock": "
|
|
57
|
-
"coverage:w3cOld": "
|
|
58
|
-
"coverage:w3c": "NODE_OPTIONS=--max_old_space_size=
|
|
59
|
-
"test:w3c": "NODE_OPTIONS=--max_old_space_size=
|
|
60
|
-
"w3c-test-only": "node --
|
|
61
|
-
"coverage:mocha": "
|
|
58
|
+
"rollup": "rollup -c",
|
|
59
|
+
"coverage:fake": "c8 --silent --no-clean mocha --reporterOptions configFile=mocha-multi-reporters.json,cmrOutput=@es-joy/json-file-reporter+output+fake --require source-map-support/register tests-polyfill/fakeIndexedDB/test-node.js",
|
|
60
|
+
"coverage:mock": "c8 --silent --no-clean mocha --reporterOptions configFile=mocha-multi-reporters.json,cmrOutput=@es-joy/json-file-reporter+output+mock --require source-map-support/register tests-polyfill/indexedDBmock/test-node.js",
|
|
61
|
+
"coverage:w3cOld": "c8 --silent --no-clean mocha --reporterOptions configFile=mocha-multi-reporters.json,cmrOutput=@es-joy/json-file-reporter+output+w3c --require source-map-support/register tests-polyfill/w3c/test-node.js",
|
|
62
|
+
"coverage:w3c": "NODE_OPTIONS=--max_old_space_size=16384 c8 --silent --no-clean npm run w3c-test-only",
|
|
63
|
+
"test:w3c": "NODE_OPTIONS=--max_old_space_size=16384 NODE_OPTIONS=--trace-warnings node test-support/node-idb-test.js",
|
|
64
|
+
"w3c-test-only": "node --trace-warnings test-support/node-idb-test.js",
|
|
65
|
+
"coverage:mocha": "c8 --silent --no-clean mocha --reporterOptions configFile=mocha-multi-reporters.json,cmrOutput=@es-joy/json-file-reporter+output+mocha --require source-map-support/register tests-mocha/test-node.js",
|
|
62
66
|
"coverage-badge": "coveradge badges/coverage-badge",
|
|
63
|
-
"coverage:report-only": "
|
|
67
|
+
"coverage:report-only": "c8 report",
|
|
64
68
|
"coverage:report": "run-s coverage:report-only",
|
|
65
69
|
"remove-cache": "rimraf node_modules/.cache",
|
|
66
70
|
"remove-cov": "rimraf .nyc_output ",
|
|
@@ -68,7 +72,7 @@
|
|
|
68
72
|
"coverage:polyfill": "run-s coverage:fake coverage:mock coverage:w3cOld",
|
|
69
73
|
"tests-badge": "mbg --fileGlob \"./test-support/results/file*.json\" --badge_output badges/tests-badge.svg",
|
|
70
74
|
"coverage": "run-s -c clean remove-cache remove-cov remove-results coverage:fake coverage:mock coverage:mocha coverage:w3c clean tests-badge coverage-badge coverage:report",
|
|
71
|
-
"open-coverage-only": "open http://
|
|
75
|
+
"open-coverage-only": "open http://127.0.0.1:9999/coverage/lcov-report/",
|
|
72
76
|
"open-coverage": "run-p start open-coverage-only",
|
|
73
77
|
"test": "run-s lint coverage",
|
|
74
78
|
"submodules-init": "git submodule update --init --recursive",
|
|
@@ -86,8 +90,8 @@
|
|
|
86
90
|
"delay": "delay 9",
|
|
87
91
|
"delayed-w3c-test": "run-s delay test:w3c",
|
|
88
92
|
"w3c-test": "run-s clean-w3c test-and-start:w3c",
|
|
89
|
-
"w3c-good-only": "node test-support/node-idb-test good",
|
|
90
|
-
"w3c-bad-only": "node test-support/node-idb-test bad",
|
|
93
|
+
"w3c-good-only": "node test-support/node-idb-test.js good",
|
|
94
|
+
"w3c-bad-only": "node test-support/node-idb-test.js bad",
|
|
91
95
|
"w3c-good": "run-s w3c-build w3c-good-only clean-w3c",
|
|
92
96
|
"w3c-bad": "run-s w3c-build w3c-bad-only clean-w3c",
|
|
93
97
|
"w3c-good-test": "run-s w3c-good-only clean-w3c",
|
|
@@ -100,9 +104,20 @@
|
|
|
100
104
|
"bugs": {
|
|
101
105
|
"url": "https://github.com/indexeddbshim/IndexedDBShim/issues"
|
|
102
106
|
},
|
|
103
|
-
"main": "dist/indexeddbshim-node.
|
|
104
|
-
"
|
|
105
|
-
|
|
107
|
+
"main": "./dist/indexeddbshim-node.cjs",
|
|
108
|
+
"exports": {
|
|
109
|
+
".": {
|
|
110
|
+
"node": {
|
|
111
|
+
"import": "./src/node-UnicodeIdentifiers.js",
|
|
112
|
+
"require": "./dist/indexeddbshim-UnicodeIdentifiers-node.cjs"
|
|
113
|
+
},
|
|
114
|
+
"default": {
|
|
115
|
+
"import": "./src/browser-noninvasive.js",
|
|
116
|
+
"require": "./dist/indexeddbshim-noninvasive.js"
|
|
117
|
+
}
|
|
118
|
+
},
|
|
119
|
+
"./*": "./*"
|
|
120
|
+
},
|
|
106
121
|
"keywords": [
|
|
107
122
|
"indexedDB",
|
|
108
123
|
"database",
|
|
@@ -132,75 +147,74 @@
|
|
|
132
147
|
"node": ">=14.0.0"
|
|
133
148
|
},
|
|
134
149
|
"dependencies": {
|
|
150
|
+
"canvas": "^2.11.2",
|
|
135
151
|
"eventtargeter": "0.8.0",
|
|
136
152
|
"sync-promise": "git+https://github.com/brettz9/sync-promise.git#full-sync-missing-promise-features",
|
|
137
|
-
"typeson": "
|
|
138
|
-
"typeson-registry": "
|
|
153
|
+
"typeson": "8.0.1",
|
|
154
|
+
"typeson-registry": "5.0.0",
|
|
139
155
|
"websql": "git+https://github.com/brettz9/node-websql.git#configurable-secure3"
|
|
140
156
|
},
|
|
141
157
|
"devDependencies": {
|
|
142
|
-
"@babel/core": "^7.
|
|
143
|
-
"@babel/preset-env": "^7.
|
|
158
|
+
"@babel/core": "^7.21.4",
|
|
159
|
+
"@babel/preset-env": "^7.21.4",
|
|
144
160
|
"@brettz9/eslint-plugin": "^1.0.4",
|
|
145
161
|
"@brettz9/node-static": "^0.1.1",
|
|
146
162
|
"@es-joy/json-file-reporter": "^1.4.0",
|
|
147
163
|
"@rollup/plugin-babel": "^6.0.3",
|
|
148
|
-
"@rollup/plugin-commonjs": "^
|
|
149
|
-
"@rollup/plugin-json": "^
|
|
150
|
-
"@rollup/plugin-node-resolve": "^15.0.
|
|
151
|
-
"@rollup/plugin-
|
|
152
|
-
"@rollup/plugin-terser": "^0.2.0",
|
|
164
|
+
"@rollup/plugin-commonjs": "^24.0.1",
|
|
165
|
+
"@rollup/plugin-json": "^6.0.0",
|
|
166
|
+
"@rollup/plugin-node-resolve": "^15.0.2",
|
|
167
|
+
"@rollup/plugin-terser": "^0.4.1",
|
|
153
168
|
"@unicode/unicode-13.0.0": "1.3.1",
|
|
154
169
|
"babel-plugin-add-module-exports": "1.0.4",
|
|
155
|
-
"bson": "^
|
|
170
|
+
"bson": "^5.2.0",
|
|
156
171
|
"builtin-modules": "^3.3.0",
|
|
157
|
-
"
|
|
172
|
+
"c8": "^7.13.0",
|
|
158
173
|
"chai": "4.3.7",
|
|
159
174
|
"chokidar-cli": "^3.0.0",
|
|
160
175
|
"colors": "1.4.0",
|
|
161
176
|
"copyfiles": "^2.4.1",
|
|
162
|
-
"core-js-bundle": "^3.
|
|
177
|
+
"core-js-bundle": "^3.30.0",
|
|
163
178
|
"coveradge": "^0.8.2",
|
|
164
179
|
"cyclonejs": "1.1.4",
|
|
165
180
|
"delay-cli": "^2.0.0",
|
|
166
|
-
"eslint": "^8.
|
|
167
|
-
"eslint-config-ash-nazg": "^34.
|
|
181
|
+
"eslint": "^8.38.0",
|
|
182
|
+
"eslint-config-ash-nazg": "^34.9.1",
|
|
168
183
|
"eslint-config-standard": "^17.0.0",
|
|
169
|
-
"eslint-plugin-array-func": "^3.1.
|
|
170
|
-
"eslint-plugin-compat": "^4.
|
|
184
|
+
"eslint-plugin-array-func": "^3.1.8",
|
|
185
|
+
"eslint-plugin-compat": "^4.1.4",
|
|
171
186
|
"eslint-plugin-eslint-comments": "^3.2.0",
|
|
172
187
|
"eslint-plugin-html": "^7.1.0",
|
|
173
|
-
"eslint-plugin-import": "^2.
|
|
174
|
-
"eslint-plugin-jsdoc": "^
|
|
188
|
+
"eslint-plugin-import": "^2.27.5",
|
|
189
|
+
"eslint-plugin-jsdoc": "^40.1.2",
|
|
175
190
|
"eslint-plugin-markdown": "^3.0.0",
|
|
176
191
|
"eslint-plugin-no-unsanitized": "^4.0.2",
|
|
177
192
|
"eslint-plugin-no-use-extend-native": "^0.5.0",
|
|
178
193
|
"eslint-plugin-node": "^11.1.0",
|
|
179
194
|
"eslint-plugin-promise": "^6.1.1",
|
|
180
|
-
"eslint-plugin-sonarjs": "^0.
|
|
195
|
+
"eslint-plugin-sonarjs": "^0.19.0",
|
|
181
196
|
"eslint-plugin-standard": "^4.1.0",
|
|
182
|
-
"eslint-plugin-unicorn": "^
|
|
183
|
-
"got": "^
|
|
197
|
+
"eslint-plugin-unicorn": "^46.0.0",
|
|
198
|
+
"got": "^12.6.0",
|
|
184
199
|
"is-date-object": "1.0.5",
|
|
185
200
|
"isomorphic-fetch": "^3.0.0",
|
|
186
|
-
"jsdom": "^
|
|
187
|
-
"license-badger": "^0.
|
|
201
|
+
"jsdom": "^21.1.1",
|
|
202
|
+
"license-badger": "^0.20.0",
|
|
188
203
|
"local-xmlhttprequest": "2.0.0",
|
|
189
|
-
"mocha": "^10.
|
|
204
|
+
"mocha": "^10.2.0",
|
|
190
205
|
"mocha-badge-generator": "^0.10.6",
|
|
191
206
|
"mocha-multi-reporters": "^1.5.1",
|
|
192
207
|
"npm-run-all": "^4.1.5",
|
|
193
|
-
"
|
|
194
|
-
"
|
|
195
|
-
"
|
|
196
|
-
"rollup": "^
|
|
197
|
-
"rollup-plugin-filesize": "^9.1.2",
|
|
208
|
+
"open-cli": "^7.2.0",
|
|
209
|
+
"rimraf": "^4.4.1",
|
|
210
|
+
"rollup": "^3.20.2",
|
|
211
|
+
"rollup-plugin-filesize": "^10.0.0",
|
|
198
212
|
"rollup-plugin-node-globals": "^1.4.0",
|
|
199
213
|
"rollup-plugin-node-polyfills": "^0.2.1",
|
|
200
|
-
"sinon": "^15.0.
|
|
214
|
+
"sinon": "^15.0.3",
|
|
201
215
|
"source-map-support": "0.5.21",
|
|
202
216
|
"sourcemap-transformer": "git+https://github.com/brettz9/sourcemap-transformer.git",
|
|
203
217
|
"w3c-blob": "0.0.1",
|
|
204
|
-
"ws": "^8.
|
|
218
|
+
"ws": "^8.13.0"
|
|
205
219
|
}
|
|
206
220
|
}
|
package/src/IDBTransaction.js
CHANGED
|
@@ -102,6 +102,7 @@ IDBTransaction.prototype.__executeRequests = function () {
|
|
|
102
102
|
// Do not set __active flag to false yet: https://github.com/w3c/IndexedDB/issues/87
|
|
103
103
|
if (e.__legacyOutputDidListenersThrowError) {
|
|
104
104
|
logError('Error', 'An error occurred in a success handler attached to request chain', e.__legacyOutputDidListenersThrowError); // We do nothing else with this error as per spec
|
|
105
|
+
// me.__active = false;
|
|
105
106
|
me.__abortTransaction(createDOMException('AbortError', 'A request was aborted (in user handler after success).'));
|
|
106
107
|
return;
|
|
107
108
|
}
|
|
@@ -1,11 +1,10 @@
|
|
|
1
|
+
import fs from 'node:fs';
|
|
2
|
+
|
|
1
3
|
import setGlobalVars from './setGlobalVars.js';
|
|
2
4
|
import nodeWebSQL from './nodeWebSQL.js'; // Importing "websql" would not gain us SQLite config ability
|
|
3
5
|
import CFG from './CFG.js';
|
|
4
6
|
import * as UnicodeIdentifiers from './UnicodeIdentifiers.js';
|
|
5
7
|
|
|
6
|
-
// eslint-disable-next-line import/no-commonjs
|
|
7
|
-
const fs = require('fs');
|
|
8
|
-
|
|
9
8
|
CFG.win = {openDatabase: nodeWebSQL};
|
|
10
9
|
|
|
11
10
|
const __setGlobalVars = function (idb, initialConfig = {}) {
|
package/src/node.js
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
|
+
import fs from 'node:fs';
|
|
2
|
+
|
|
1
3
|
import setGlobalVars from './setGlobalVars.js';
|
|
2
4
|
import nodeWebSQL from './nodeWebSQL.js'; // Importing "websql" would not gain us SQLite config ability
|
|
3
5
|
import CFG from './CFG.js';
|
|
4
6
|
|
|
5
|
-
// eslint-disable-next-line import/no-commonjs
|
|
6
|
-
const fs = require('fs');
|
|
7
|
-
|
|
8
7
|
CFG.win = {openDatabase: nodeWebSQL};
|
|
9
8
|
|
|
10
9
|
const __setGlobalVars = function (idb, initialConfig = {}) {
|