diff --git a/esbuild-plugins.js b/esbuild-plugins.js new file mode 100644 index 00000000..9ad62026 --- /dev/null +++ b/esbuild-plugins.js @@ -0,0 +1,74 @@ +/** + * this plugin resolves to a browser version of compression.js that + * does not include LZO or Brötli comprssion. + */ +const compressionBrowserPlugin = { + name: 'compressionBrowser', + setup(build) { + let path = require('path') + build.onResolve({filter: /^\.\/compression$/}, args => { + return { + path: path.resolve(__dirname, "lib","browser","compression.js") + } + }) + } +} + +// Lifted from https://esbuild.github.io/plugins/#webassembly-plugin +const wasmPlugin = { + name: 'wasm', + setup(build) { + let path = require('path') + let fs = require('fs') + + // Resolve ".wasm" files to a path with a namespace + build.onResolve({ filter: /\.wasm$/ }, args => { + // If this is the import inside the stub module, import the + // binary itself. Put the path in the "wasm-binary" namespace + // to tell our binary load callback to load the binary file. + if (args.namespace === 'wasm-stub') { + return { + path: args.path, + namespace: 'wasm-binary', + } + } + + // Otherwise, generate the JavaScript stub module for this + // ".wasm" file. Put it in the "wasm-stub" namespace to tell + // our stub load callback to fill it with JavaScript. + // + // Resolve relative paths to absolute paths here since this + // resolve callback is given "resolveDir", the directory to + // resolve imports against. + if (args.resolveDir === '') { + return // Ignore unresolvable paths + } + return { + path: path.isAbsolute(args.path) ? args.path : path.join(args.resolveDir, args.path), + namespace: 'wasm-stub', + } + }) + + // Virtual modules in the "wasm-stub" namespace are filled with + // the JavaScript code for compiling the WebAssembly binary. The + // binary itself is imported from a second virtual module. + build.onLoad({ filter: /.*/, namespace: 'wasm-stub' }, async (args) => ({ + contents: `import wasm from ${JSON.stringify(args.path)} + export default (imports) => + WebAssembly.instantiate(wasm, imports).then( + result => result.instance.exports)`, + })) + + // Virtual modules in the "wasm-binary" namespace contain the + // actual bytes of the WebAssembly file. This uses esbuild's + // built-in "binary" loader instead of manually embedding the + // binary data inside JavaScript code ourselves. + build.onLoad({ filter: /.*/, namespace: 'wasm-binary' }, async (args) => ({ + contents: await fs.promises.readFile(args.path), + loader: 'binary', + })) + }, +} + +module.exports = { compressionBrowserPlugin, wasmPlugin} + diff --git a/esbuild-serve.js b/esbuild-serve.js new file mode 100644 index 00000000..5380bffe --- /dev/null +++ b/esbuild-serve.js @@ -0,0 +1,20 @@ +import { compressionBrowserPlugin, wasmPlugin} from "./esbuild-plugins"; +// esbuild has TypeScript support by default +require('esbuild') + .serve({ + servedir: __dirname, + }, { + entryPoints: ['parquet.js'], + outfile: 'main.js', + define: {"process.env.NODE_DEBUG": false, "process.env.NODE_ENV": "\"production\"", global: "window" }, + platform: 'browser', + plugins: [compressionBrowserPlugin,wasmPlugin], + sourcemap: "external", + bundle: true, + globalName: 'parquetjs', + inject: ['./esbuild-shims.js'] + }).then(server => { + console.log("serving parquetjs", server) + // Call "stop" on the web server when you're done + // server.stop() + }) diff --git a/esbuild.js b/esbuild.js new file mode 100644 index 00000000..e38398ab --- /dev/null +++ b/esbuild.js @@ -0,0 +1,32 @@ +const path = require("path") +const {compressionBrowserPlugin, wasmPlugin} = require("./esbuild-plugins"); +// esbuild has TypeScript support by default +const outfile = 'parquet-bundle.min.js' +require('esbuild') + .build({ + bundle: true, + entryPoints: ['parquet.js'], + outdir: path.resolve(__dirname, "dist","browser"), + define: { + "process.env.NODE_DEBUG": false, + "process.env.NODE_ENV": "\"production\"", + global: "window" + }, + globalName: 'parquetjs', + inject: ['./esbuild-shims.js'], + minify: true, + platform: 'browser', // default + plugins: [compressionBrowserPlugin, wasmPlugin], + target: "esnext" // default + }) + .then(res => { + if (!res.warnings.length) { + console.log("built with no errors or warnings") + } + }) + .catch(e => { + console.error("Finished with errors: ", e.toString()); + }); + + + diff --git a/examples/server/README.md b/examples/server/README.md new file mode 100644 index 00000000..995d471c --- /dev/null +++ b/examples/server/README.md @@ -0,0 +1,8 @@ +# Example Server +This is a toy server that illustrates how to use the parquetjs library built with esbuild. +To run it: +1. npm install +1. View and edit the files in `views` to taste +1. node app.js +1. Build and serve the parquetjs bundle +1. visit `http://localhost:3000` and click buttons, do things in the console. diff --git a/examples/server/app.js b/examples/server/app.js new file mode 100644 index 00000000..e65a329e --- /dev/null +++ b/examples/server/app.js @@ -0,0 +1,20 @@ +const express = require('express') +const path = require("path") +const app = express() +const port = 3000 + +app.use(express.static(path.join(__dirname, 'public'))); +app.engine('ejs', require('ejs').__express); + +app.set('view engine', 'ejs'); + +app.get('/', (req, res) => { + res.render('parquetFiles', { + // files: "fruits, fruits-no-index".split(','), + title: "Parquet Files", + }) +}) + +app.listen(port, () => { + console.log(`Example app listening at http://localhost:${port}`) +}) diff --git a/examples/server/package.json b/examples/server/package.json new file mode 100644 index 00000000..82401dc8 --- /dev/null +++ b/examples/server/package.json @@ -0,0 +1,10 @@ +{ + "name": "untitled", + "version": "1.0.0", + "main": "index.js", + "license": "MIT", + "dependencies": { + "@dsnp/parquetjs": "../parquetjs", + "ejs": "^3.1.6" + } +} diff --git a/examples/server/views/footer.ejs b/examples/server/views/footer.ejs new file mode 100644 index 00000000..308b1d01 --- /dev/null +++ b/examples/server/views/footer.ejs @@ -0,0 +1,2 @@ + + diff --git a/examples/server/views/header.ejs b/examples/server/views/header.ejs new file mode 100644 index 00000000..3ba3dd90 --- /dev/null +++ b/examples/server/views/header.ejs @@ -0,0 +1,10 @@ + + + + + + <%= title %> + + + + diff --git a/examples/server/views/parquetFiles.ejs b/examples/server/views/parquetFiles.ejs new file mode 100644 index 00000000..76ae9751 --- /dev/null +++ b/examples/server/views/parquetFiles.ejs @@ -0,0 +1,44 @@ + +<%- include("./header.ejs", {title: "Parquet files" }) %> + + + +

Search fruits-bloomfilter.parquet "name" column for

+ + +<%- include("./footer.ejs") %> diff --git a/lib/bloomFilterIO/bloomFilterReader.ts b/lib/bloomFilterIO/bloomFilterReader.ts index 76cb269d..ecd9509c 100644 --- a/lib/bloomFilterIO/bloomFilterReader.ts +++ b/lib/bloomFilterIO/bloomFilterReader.ts @@ -8,14 +8,10 @@ const filterColumnChunksWithBloomFilters = ( columnChunkDataCollection: Array ) => { return columnChunkDataCollection.filter((columnChunk) => { - const { - column: { - meta_data: { - bloom_filter_offset: { buffer: bloomFilterOffsetBuffer }, - }, - }, - } = columnChunk; - return bloomFilterOffsetBuffer; + if (!columnChunk.column.meta_data.bloom_filter_offset) { + return null + } + return columnChunk?.column?.meta_data?.bloom_filter_offset?.buffer }); }; diff --git a/lib/codec/plain.js b/lib/codec/plain.js index 068e5c0b..57afe069 100644 --- a/lib/codec/plain.js +++ b/lib/codec/plain.js @@ -49,7 +49,6 @@ function decodeValues_INT32(cursor, count) { function encodeValues_INT64(values) { let buf = Buffer.alloc(8 * values.length); for (let i = 0; i < values.length; i++) { - //console.log(typeof values[i]); buf.writeBigInt64LE(BigInt(values[i]), i*8); } diff --git a/lib/compression.js b/lib/compression.js index 67884b9f..805b06f2 100644 --- a/lib/compression.js +++ b/lib/compression.js @@ -2,7 +2,8 @@ const zlib = require('zlib'); const snappy = require('snappyjs'); // const lzo = require('lzo'); -import wasmBrotli from 'wasm-brotli' +import { compress as brotliCompress, decompress as brotliDecompress } from 'wasm-brotli' + const PARQUET_COMPRESSION_METHODS = { 'UNCOMPRESSED': { @@ -17,10 +18,11 @@ const PARQUET_COMPRESSION_METHODS = { deflate: deflate_snappy, inflate: inflate_snappy }, - 'LZO': { - deflate: deflate_lzo, - inflate: inflate_lzo - }, + // Disabled. See: https://github.com/LibertyDSNP/parquetjs/issues/18 + // 'LZO': { + // deflate: deflate_lzo, + // inflate: inflate_lzo + // }, 'BROTLI': { deflate: deflate_brotli, inflate: inflate_brotli @@ -49,14 +51,13 @@ function deflate_gzip(value) { function deflate_snappy(value) { return snappy.compress(value); } - -function deflate_lzo(value) { - return lzo.compress(value); -} +// +// function deflate_lzo(value) { +// return lzo.compress(value); +// } async function deflate_brotli(value) { - const { compress } = await wasmBrotli - const compressedContent = compress(value, { + const compressedContent = await brotliCompress(value, { mode: 0, quality: 8, lgwin: 22 @@ -86,15 +87,15 @@ function inflate_gzip(value) { function inflate_snappy(value) { return snappy.uncompress(value); } - -function inflate_lzo(value) { - return lzo.decompress(value); -} +// +// function inflate_lzo(value) { +// return lzo.decompress(value); +// } async function inflate_brotli(value) { - const { uncompress } = await wasmBrotli - const uncompressedContent = uncompress(value) + const uncompressedContent = await brotliDecompress(value) return Buffer.from(uncompressedContent); } module.exports = { PARQUET_COMPRESSION_METHODS, deflate, inflate }; + diff --git a/package-lock.json b/package-lock.json index 71b39b95..0955dbcb 100644 --- a/package-lock.json +++ b/package-lock.json @@ -17,6 +17,7 @@ "browserify-zlib": "^0.2.0", "bson": "4.4.0", "cross-fetch": "^3.1.4", + "esbuild": "^0.12.11", "events": "^3.3.0", "int53": "^0.2.4", "lodash": "^4.17.21", @@ -56,9 +57,9 @@ "ts-loader": "^9.2.3", "ts-node": "^9.1.1", "typescript": "^4.3.4", - "webpack": "^5.41.0", "webpack-cli": "^4.7.2", - "webpack-dev-server": "^3.11.2" + "webpack-dev-server": "^3.11.2", + "xxhashjs": "^0.2.2" }, "engines": { "node": ">=14.16.0" @@ -1762,6 +1763,7 @@ "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-7.2.13.tgz", "integrity": "sha512-LKmQCWAlnVHvvXq4oasNUMTJJb2GwSyTY8+1C7OH5ILR8mPLaljv1jxL1bXW3xB3jFbQxTKxJAvI8PyjB09aBg==", "dev": true, + "peer": true, "dependencies": { "@types/estree": "*", "@types/json-schema": "*" @@ -1772,6 +1774,7 @@ "resolved": "https://registry.npmjs.org/@types/eslint-scope/-/eslint-scope-3.7.0.tgz", "integrity": "sha512-O/ql2+rrCUe2W2rs7wMR+GqPRcgB6UiqN5RhrR5xruFlY7l9YLMn0ZkDzjoHLeiFkR8MCQZVudUuuvQ2BLC9Qw==", "dev": true, + "peer": true, "dependencies": { "@types/eslint": "*", "@types/estree": "*" @@ -1781,7 +1784,8 @@ "version": "0.0.48", "resolved": "https://registry.npmjs.org/@types/estree/-/estree-0.0.48.tgz", "integrity": "sha512-LfZwXoGUDo0C3me81HXgkBg5CTQYb6xzEl+fNmbO4JdRiSKQ8A0GD1OBBvKAIsbCUgoyAty7m99GqqMQe784ew==", - "dev": true + "dev": true, + "peer": true }, "node_modules/@types/glob": { "version": "7.1.3", @@ -1904,6 +1908,7 @@ "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.11.0.tgz", "integrity": "sha512-kX2W49LWsbthrmIRMbQZuQDhGtjyqXfEmmHyEi4XWnSZtPmxY0+3anPIzsnRb45VH/J55zlOfWvZuY47aJZTJg==", "dev": true, + "peer": true, "dependencies": { "@webassemblyjs/helper-numbers": "1.11.0", "@webassemblyjs/helper-wasm-bytecode": "1.11.0" @@ -1913,25 +1918,29 @@ "version": "1.11.0", "resolved": "https://registry.npmjs.org/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.11.0.tgz", "integrity": "sha512-Q/aVYs/VnPDVYvsCBL/gSgwmfjeCb4LW8+TMrO3cSzJImgv8lxxEPM2JA5jMrivE7LSz3V+PFqtMbls3m1exDA==", - "dev": true + "dev": true, + "peer": true }, "node_modules/@webassemblyjs/helper-api-error": { "version": "1.11.0", "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-api-error/-/helper-api-error-1.11.0.tgz", "integrity": "sha512-baT/va95eXiXb2QflSx95QGT5ClzWpGaa8L7JnJbgzoYeaA27FCvuBXU758l+KXWRndEmUXjP0Q5fibhavIn8w==", - "dev": true + "dev": true, + "peer": true }, "node_modules/@webassemblyjs/helper-buffer": { "version": "1.11.0", "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.11.0.tgz", "integrity": "sha512-u9HPBEl4DS+vA8qLQdEQ6N/eJQ7gT7aNvMIo8AAWvAl/xMrcOSiI2M0MAnMCy3jIFke7bEee/JwdX1nUpCtdyA==", - "dev": true + "dev": true, + "peer": true }, "node_modules/@webassemblyjs/helper-numbers": { "version": "1.11.0", "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-numbers/-/helper-numbers-1.11.0.tgz", "integrity": "sha512-DhRQKelIj01s5IgdsOJMKLppI+4zpmcMQ3XboFPLwCpSNH6Hqo1ritgHgD0nqHeSYqofA6aBN/NmXuGjM1jEfQ==", "dev": true, + "peer": true, "dependencies": { "@webassemblyjs/floating-point-hex-parser": "1.11.0", "@webassemblyjs/helper-api-error": "1.11.0", @@ -1942,13 +1951,15 @@ "version": "1.11.0", "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.11.0.tgz", "integrity": "sha512-MbmhvxXExm542tWREgSFnOVo07fDpsBJg3sIl6fSp9xuu75eGz5lz31q7wTLffwL3Za7XNRCMZy210+tnsUSEA==", - "dev": true + "dev": true, + "peer": true }, "node_modules/@webassemblyjs/helper-wasm-section": { "version": "1.11.0", "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.11.0.tgz", "integrity": "sha512-3Eb88hcbfY/FCukrg6i3EH8H2UsD7x8Vy47iVJrP967A9JGqgBVL9aH71SETPx1JrGsOUVLo0c7vMCN22ytJew==", "dev": true, + "peer": true, "dependencies": { "@webassemblyjs/ast": "1.11.0", "@webassemblyjs/helper-buffer": "1.11.0", @@ -1961,6 +1972,7 @@ "resolved": "https://registry.npmjs.org/@webassemblyjs/ieee754/-/ieee754-1.11.0.tgz", "integrity": "sha512-KXzOqpcYQwAfeQ6WbF6HXo+0udBNmw0iXDmEK5sFlmQdmND+tr773Ti8/5T/M6Tl/413ArSJErATd8In3B+WBA==", "dev": true, + "peer": true, "dependencies": { "@xtuc/ieee754": "^1.2.0" } @@ -1970,6 +1982,7 @@ "resolved": "https://registry.npmjs.org/@webassemblyjs/leb128/-/leb128-1.11.0.tgz", "integrity": "sha512-aqbsHa1mSQAbeeNcl38un6qVY++hh8OpCOzxhixSYgbRfNWcxJNJQwe2rezK9XEcssJbbWIkblaJRwGMS9zp+g==", "dev": true, + "peer": true, "dependencies": { "@xtuc/long": "4.2.2" } @@ -1978,13 +1991,15 @@ "version": "1.11.0", "resolved": "https://registry.npmjs.org/@webassemblyjs/utf8/-/utf8-1.11.0.tgz", "integrity": "sha512-A/lclGxH6SpSLSyFowMzO/+aDEPU4hvEiooCMXQPcQFPPJaYcPQNKGOCLUySJsYJ4trbpr+Fs08n4jelkVTGVw==", - "dev": true + "dev": true, + "peer": true }, "node_modules/@webassemblyjs/wasm-edit": { "version": "1.11.0", "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.11.0.tgz", "integrity": "sha512-JHQ0damXy0G6J9ucyKVXO2j08JVJ2ntkdJlq1UTiUrIgfGMmA7Ik5VdC/L8hBK46kVJgujkBIoMtT8yVr+yVOQ==", "dev": true, + "peer": true, "dependencies": { "@webassemblyjs/ast": "1.11.0", "@webassemblyjs/helper-buffer": "1.11.0", @@ -2001,6 +2016,7 @@ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.11.0.tgz", "integrity": "sha512-BEUv1aj0WptCZ9kIS30th5ILASUnAPEvE3tVMTrItnZRT9tXCLW2LEXT8ezLw59rqPP9klh9LPmpU+WmRQmCPQ==", "dev": true, + "peer": true, "dependencies": { "@webassemblyjs/ast": "1.11.0", "@webassemblyjs/helper-wasm-bytecode": "1.11.0", @@ -2014,6 +2030,7 @@ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.11.0.tgz", "integrity": "sha512-tHUSP5F4ywyh3hZ0+fDQuWxKx3mJiPeFufg+9gwTpYp324mPCQgnuVKwzLTZVqj0duRDovnPaZqDwoyhIO8kYg==", "dev": true, + "peer": true, "dependencies": { "@webassemblyjs/ast": "1.11.0", "@webassemblyjs/helper-buffer": "1.11.0", @@ -2026,6 +2043,7 @@ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.11.0.tgz", "integrity": "sha512-6L285Sgu9gphrcpDXINvm0M9BskznnzJTE7gYkjDbxET28shDqp27wpruyx3C2S/dvEwiigBwLA1cz7lNUi0kw==", "dev": true, + "peer": true, "dependencies": { "@webassemblyjs/ast": "1.11.0", "@webassemblyjs/helper-api-error": "1.11.0", @@ -2040,6 +2058,7 @@ "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.11.0.tgz", "integrity": "sha512-Fg5OX46pRdTgB7rKIUojkh9vXaVN6sGYCnEiJN1GYkb0RPwShZXp6KTDqmoMdQPKhcroOXh3fEzmkWmCYaKYhQ==", "dev": true, + "peer": true, "dependencies": { "@webassemblyjs/ast": "1.11.0", "@xtuc/long": "4.2.2" @@ -2105,13 +2124,15 @@ "version": "1.2.0", "resolved": "https://registry.npmjs.org/@xtuc/ieee754/-/ieee754-1.2.0.tgz", "integrity": "sha512-DX8nKgqcGwsc0eJSqYt5lwP4DH5FlHnmuWWBRy7X0NcaGR0ZtuyeESgMwTYVEtxmsNGY+qit4QYT/MIYTOTPeA==", - "dev": true + "dev": true, + "peer": true }, "node_modules/@xtuc/long": { "version": "4.2.2", "resolved": "https://registry.npmjs.org/@xtuc/long/-/long-4.2.2.tgz", "integrity": "sha512-NuHqBY1PB/D8xU6s/thBgOAiAP7HOYDQ32+BFZILJ8ivkUkAHQnWfn6WhL79Owj1qmUnoN/YPhktdIoucipkAQ==", - "dev": true + "dev": true, + "peer": true }, "node_modules/abab": { "version": "2.0.5", @@ -2137,6 +2158,7 @@ "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.4.0.tgz", "integrity": "sha512-ULr0LDaEqQrMFGyQ3bhJkLsbtrQ8QibAseGZeaSUiT/6zb9IvIkomWHJIvgvwad+hinRAgsI51JcWk2yvwyL+w==", "dev": true, + "peer": true, "bin": { "acorn": "bin/acorn" }, @@ -3015,6 +3037,7 @@ "resolved": "https://registry.npmjs.org/chrome-trace-event/-/chrome-trace-event-1.0.3.tgz", "integrity": "sha512-p3KULyQg4S7NIHixdwbGX+nFHkoBiA4YQmyWtjb8XngSKV124nJmRysgAeujbUVb15vh+RvFUfCPqU7rXk+hZg==", "dev": true, + "peer": true, "engines": { "node": ">=6.0" } @@ -3305,7 +3328,8 @@ "version": "2.20.3", "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", - "dev": true + "dev": true, + "peer": true }, "node_modules/commondir": { "version": "1.0.1", @@ -3531,6 +3555,12 @@ "node": ">= 8" } }, + "node_modules/cuint": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/cuint/-/cuint-0.2.2.tgz", + "integrity": "sha1-QICG1AlVDCYxFVYZ6fp7ytw7mRs=", + "dev": true + }, "node_modules/dargs": { "version": "6.1.0", "resolved": "https://registry.npmjs.org/dargs/-/dargs-6.1.0.tgz", @@ -4100,7 +4130,8 @@ "version": "0.6.0", "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-0.6.0.tgz", "integrity": "sha512-f8kcHX1ArhllUtb/wVSyvygoKCznIjnxhLxy7TCvIiMdT7fL4ZDTIKaadMe6eLvOXg6Wk02UeoFgUoZ2EKZZUA==", - "dev": true + "dev": true, + "peer": true }, "node_modules/es-to-primitive": { "version": "1.2.1", @@ -4123,6 +4154,15 @@ "resolved": "https://registry.npmjs.org/es6-object-assign/-/es6-object-assign-1.1.0.tgz", "integrity": "sha1-wsNYJlYkfDnqEHyx5mUrb58kUjw=" }, + "node_modules/esbuild": { + "version": "0.12.11", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.12.11.tgz", + "integrity": "sha512-h83GwI6lYOrnSv5hSY2i2XZ191v3haj2IGDzwrkfWHhuO/kVMX3RYjhwRNG9E5VSxVLPaUjTVwrv8HWLvhk2nQ==", + "hasInstallScript": true, + "bin": { + "esbuild": "bin/esbuild" + } + }, "node_modules/escalade": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz", @@ -4152,6 +4192,7 @@ "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-5.1.1.tgz", "integrity": "sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw==", "dev": true, + "peer": true, "dependencies": { "esrecurse": "^4.3.0", "estraverse": "^4.1.1" @@ -4165,6 +4206,7 @@ "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz", "integrity": "sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==", "dev": true, + "peer": true, "dependencies": { "estraverse": "^5.2.0" }, @@ -4177,6 +4219,7 @@ "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.2.0.tgz", "integrity": "sha512-BxbNGGNm0RyRYvUdHpIwv9IWzeM9XClbOxwoATuFdOE7ZE6wHL+HQ5T8hoPM+zHvmKzzsEqhgy0GrQ5X13afiQ==", "dev": true, + "peer": true, "engines": { "node": ">=4.0" } @@ -4186,6 +4229,7 @@ "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-4.3.0.tgz", "integrity": "sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==", "dev": true, + "peer": true, "engines": { "node": ">=4.0" } @@ -5159,7 +5203,8 @@ "version": "0.4.1", "resolved": "https://registry.npmjs.org/glob-to-regexp/-/glob-to-regexp-0.4.1.tgz", "integrity": "sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw==", - "dev": true + "dev": true, + "peer": true }, "node_modules/globals": { "version": "11.12.0", @@ -6392,6 +6437,7 @@ "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-27.0.2.tgz", "integrity": "sha512-EoBdilOTTyOgmHXtw/cPc+ZrCA0KJMrkXzkrPGNwLmnvvlN1nj7MPrxpT7m+otSv2e1TLaVffzDnE/LB14zJMg==", "dev": true, + "peer": true, "dependencies": { "@types/node": "*", "merge-stream": "^2.0.0", @@ -6406,6 +6452,7 @@ "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "peer": true, "engines": { "node": ">=8" } @@ -6415,6 +6462,7 @@ "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", "dev": true, + "peer": true, "dependencies": { "has-flag": "^4.0.0" }, @@ -6468,7 +6516,8 @@ "version": "1.0.2", "resolved": "https://registry.npmjs.org/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz", "integrity": "sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw==", - "dev": true + "dev": true, + "peer": true }, "node_modules/json-parse-even-better-errors": { "version": "2.3.1", @@ -6572,6 +6621,7 @@ "resolved": "https://registry.npmjs.org/loader-runner/-/loader-runner-4.2.0.tgz", "integrity": "sha512-92+huvxMvYlMzMt0iIOukcwYBFpkYJdpl2xsZ7LrlayO7E8SOv+JJUEK17B/dJIHAOLMfh2dZZ/Y18WgmGtYNw==", "dev": true, + "peer": true, "engines": { "node": ">=6.11.5" } @@ -7436,7 +7486,8 @@ "version": "2.6.2", "resolved": "https://registry.npmjs.org/neo-async/-/neo-async-2.6.2.tgz", "integrity": "sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==", - "dev": true + "dev": true, + "peer": true }, "node_modules/nice-try": { "version": "1.0.5", @@ -8873,6 +8924,7 @@ "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.0.0.tgz", "integrity": "sha512-6D82/xSzO094ajanoOSbe4YvXWMfn2A//8Y1+MUqFAJul5Bs+yn36xbK9OtNDcRVSBJ9jjeoXftM6CfztsjOAA==", "dev": true, + "peer": true, "dependencies": { "@types/json-schema": "^7.0.6", "ajv": "^6.12.5", @@ -9506,7 +9558,8 @@ "version": "2.0.1", "resolved": "https://registry.npmjs.org/source-list-map/-/source-list-map-2.0.1.tgz", "integrity": "sha512-qnQ7gVMxGNxsiL4lEuJwe/To8UnK7fAnmbGEEH8RpLouuKbeEm0lhbQVFIrNSuB+G7tVrAlVsZgETT5nljf+Iw==", - "dev": true + "dev": true, + "peer": true }, "node_modules/source-map": { "version": "0.5.7", @@ -9952,6 +10005,7 @@ "resolved": "https://registry.npmjs.org/terser/-/terser-5.7.0.tgz", "integrity": "sha512-HP5/9hp2UaZt5fYkuhNBR8YyRcT8juw8+uFbAme53iN9hblvKnLUTKkmwJG6ocWpIKf8UK4DoeWG4ty0J6S6/g==", "dev": true, + "peer": true, "dependencies": { "commander": "^2.20.0", "source-map": "~0.7.2", @@ -9969,6 +10023,7 @@ "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.1.3.tgz", "integrity": "sha512-cxGbMqr6+A2hrIB5ehFIF+F/iST5ZOxvOmy9zih9ySbP1C2oEWQSOUS+2SNBTjzx5xLKO4xnod9eywdfq1Nb9A==", "dev": true, + "peer": true, "dependencies": { "jest-worker": "^27.0.2", "p-limit": "^3.1.0", @@ -9993,6 +10048,7 @@ "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", "dev": true, + "peer": true, "engines": { "node": ">=0.10.0" } @@ -10002,6 +10058,7 @@ "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.7.3.tgz", "integrity": "sha512-CkCj6giN3S+n9qrYiBTX5gystlENnRW5jZeNLHpe6aue+SrHcG5VYwujhW9s4dY31mEGsxBDrHR6oI69fTXsaQ==", "dev": true, + "peer": true, "engines": { "node": ">= 8" } @@ -10703,6 +10760,7 @@ "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.2.0.tgz", "integrity": "sha512-up4YAn/XHgZHIxFBVCdlMiWDj6WaLKpwVeGQk2I5thdYxF/KmF0aaz6TfJZ/hfl1h/XlcDr7k1KH7ThDagpFaA==", "dev": true, + "peer": true, "dependencies": { "glob-to-regexp": "^0.4.1", "graceful-fs": "^4.1.2" @@ -10734,6 +10792,7 @@ "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.41.0.tgz", "integrity": "sha512-pCVO7hVm8XiL6DpPtXrFLS8ktmH/tpvtbEex6hn4RweTFe6z6Cugh5FlQoEPZotb15HiirjM2Kv7THTA7sKLzQ==", "dev": true, + "peer": true, "dependencies": { "@types/eslint-scope": "^3.7.0", "@types/estree": "^0.0.48", @@ -11586,6 +11645,7 @@ "resolved": "https://registry.npmjs.org/webpack-sources/-/webpack-sources-2.3.0.tgz", "integrity": "sha512-WyOdtwSvOML1kbgtXbTDnEW0jkJ7hZr/bDByIwszhWd/4XX1A3XMkrbFMsuH4+/MfLlZCUzlAdg4r7jaGKEIgQ==", "dev": true, + "peer": true, "dependencies": { "source-list-map": "^2.0.1", "source-map": "^0.6.1" @@ -11599,6 +11659,7 @@ "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", "dev": true, + "peer": true, "engines": { "node": ">=0.10.0" } @@ -11847,6 +11908,15 @@ "resolved": "https://registry.npmjs.org/xxhash-wasm/-/xxhash-wasm-0.4.1.tgz", "integrity": "sha512-sAaACjH5Th5O2Y1Pl6Mm03bHdie8htTm7ZG146by2ITXuxD1Ksx46ZEOYaDhtlCY3fHrmDfdvzTOGzO1R00COA==" }, + "node_modules/xxhashjs": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/xxhashjs/-/xxhashjs-0.2.2.tgz", + "integrity": "sha512-AkTuIuVTET12tpsVIQo+ZU6f/qDmKuRUcjaqR+OIvm+aCBsZ95i7UVY5WJ9TMsSaZ0DA2WxoZ4acu0sPH+OKAw==", + "dev": true, + "dependencies": { + "cuint": "^0.2.2" + } + }, "node_modules/y18n": { "version": "5.0.8", "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", @@ -13694,6 +13764,7 @@ "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-7.2.13.tgz", "integrity": "sha512-LKmQCWAlnVHvvXq4oasNUMTJJb2GwSyTY8+1C7OH5ILR8mPLaljv1jxL1bXW3xB3jFbQxTKxJAvI8PyjB09aBg==", "dev": true, + "peer": true, "requires": { "@types/estree": "*", "@types/json-schema": "*" @@ -13704,6 +13775,7 @@ "resolved": "https://registry.npmjs.org/@types/eslint-scope/-/eslint-scope-3.7.0.tgz", "integrity": "sha512-O/ql2+rrCUe2W2rs7wMR+GqPRcgB6UiqN5RhrR5xruFlY7l9YLMn0ZkDzjoHLeiFkR8MCQZVudUuuvQ2BLC9Qw==", "dev": true, + "peer": true, "requires": { "@types/eslint": "*", "@types/estree": "*" @@ -13713,7 +13785,8 @@ "version": "0.0.48", "resolved": "https://registry.npmjs.org/@types/estree/-/estree-0.0.48.tgz", "integrity": "sha512-LfZwXoGUDo0C3me81HXgkBg5CTQYb6xzEl+fNmbO4JdRiSKQ8A0GD1OBBvKAIsbCUgoyAty7m99GqqMQe784ew==", - "dev": true + "dev": true, + "peer": true }, "@types/glob": { "version": "7.1.3", @@ -13836,6 +13909,7 @@ "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.11.0.tgz", "integrity": "sha512-kX2W49LWsbthrmIRMbQZuQDhGtjyqXfEmmHyEi4XWnSZtPmxY0+3anPIzsnRb45VH/J55zlOfWvZuY47aJZTJg==", "dev": true, + "peer": true, "requires": { "@webassemblyjs/helper-numbers": "1.11.0", "@webassemblyjs/helper-wasm-bytecode": "1.11.0" @@ -13845,25 +13919,29 @@ "version": "1.11.0", "resolved": "https://registry.npmjs.org/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.11.0.tgz", "integrity": "sha512-Q/aVYs/VnPDVYvsCBL/gSgwmfjeCb4LW8+TMrO3cSzJImgv8lxxEPM2JA5jMrivE7LSz3V+PFqtMbls3m1exDA==", - "dev": true + "dev": true, + "peer": true }, "@webassemblyjs/helper-api-error": { "version": "1.11.0", "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-api-error/-/helper-api-error-1.11.0.tgz", "integrity": "sha512-baT/va95eXiXb2QflSx95QGT5ClzWpGaa8L7JnJbgzoYeaA27FCvuBXU758l+KXWRndEmUXjP0Q5fibhavIn8w==", - "dev": true + "dev": true, + "peer": true }, "@webassemblyjs/helper-buffer": { "version": "1.11.0", "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.11.0.tgz", "integrity": "sha512-u9HPBEl4DS+vA8qLQdEQ6N/eJQ7gT7aNvMIo8AAWvAl/xMrcOSiI2M0MAnMCy3jIFke7bEee/JwdX1nUpCtdyA==", - "dev": true + "dev": true, + "peer": true }, "@webassemblyjs/helper-numbers": { "version": "1.11.0", "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-numbers/-/helper-numbers-1.11.0.tgz", "integrity": "sha512-DhRQKelIj01s5IgdsOJMKLppI+4zpmcMQ3XboFPLwCpSNH6Hqo1ritgHgD0nqHeSYqofA6aBN/NmXuGjM1jEfQ==", "dev": true, + "peer": true, "requires": { "@webassemblyjs/floating-point-hex-parser": "1.11.0", "@webassemblyjs/helper-api-error": "1.11.0", @@ -13874,13 +13952,15 @@ "version": "1.11.0", "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.11.0.tgz", "integrity": "sha512-MbmhvxXExm542tWREgSFnOVo07fDpsBJg3sIl6fSp9xuu75eGz5lz31q7wTLffwL3Za7XNRCMZy210+tnsUSEA==", - "dev": true + "dev": true, + "peer": true }, "@webassemblyjs/helper-wasm-section": { "version": "1.11.0", "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.11.0.tgz", "integrity": "sha512-3Eb88hcbfY/FCukrg6i3EH8H2UsD7x8Vy47iVJrP967A9JGqgBVL9aH71SETPx1JrGsOUVLo0c7vMCN22ytJew==", "dev": true, + "peer": true, "requires": { "@webassemblyjs/ast": "1.11.0", "@webassemblyjs/helper-buffer": "1.11.0", @@ -13893,6 +13973,7 @@ "resolved": "https://registry.npmjs.org/@webassemblyjs/ieee754/-/ieee754-1.11.0.tgz", "integrity": "sha512-KXzOqpcYQwAfeQ6WbF6HXo+0udBNmw0iXDmEK5sFlmQdmND+tr773Ti8/5T/M6Tl/413ArSJErATd8In3B+WBA==", "dev": true, + "peer": true, "requires": { "@xtuc/ieee754": "^1.2.0" } @@ -13902,6 +13983,7 @@ "resolved": "https://registry.npmjs.org/@webassemblyjs/leb128/-/leb128-1.11.0.tgz", "integrity": "sha512-aqbsHa1mSQAbeeNcl38un6qVY++hh8OpCOzxhixSYgbRfNWcxJNJQwe2rezK9XEcssJbbWIkblaJRwGMS9zp+g==", "dev": true, + "peer": true, "requires": { "@xtuc/long": "4.2.2" } @@ -13910,13 +13992,15 @@ "version": "1.11.0", "resolved": "https://registry.npmjs.org/@webassemblyjs/utf8/-/utf8-1.11.0.tgz", "integrity": "sha512-A/lclGxH6SpSLSyFowMzO/+aDEPU4hvEiooCMXQPcQFPPJaYcPQNKGOCLUySJsYJ4trbpr+Fs08n4jelkVTGVw==", - "dev": true + "dev": true, + "peer": true }, "@webassemblyjs/wasm-edit": { "version": "1.11.0", "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.11.0.tgz", "integrity": "sha512-JHQ0damXy0G6J9ucyKVXO2j08JVJ2ntkdJlq1UTiUrIgfGMmA7Ik5VdC/L8hBK46kVJgujkBIoMtT8yVr+yVOQ==", "dev": true, + "peer": true, "requires": { "@webassemblyjs/ast": "1.11.0", "@webassemblyjs/helper-buffer": "1.11.0", @@ -13933,6 +14017,7 @@ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.11.0.tgz", "integrity": "sha512-BEUv1aj0WptCZ9kIS30th5ILASUnAPEvE3tVMTrItnZRT9tXCLW2LEXT8ezLw59rqPP9klh9LPmpU+WmRQmCPQ==", "dev": true, + "peer": true, "requires": { "@webassemblyjs/ast": "1.11.0", "@webassemblyjs/helper-wasm-bytecode": "1.11.0", @@ -13946,6 +14031,7 @@ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.11.0.tgz", "integrity": "sha512-tHUSP5F4ywyh3hZ0+fDQuWxKx3mJiPeFufg+9gwTpYp324mPCQgnuVKwzLTZVqj0duRDovnPaZqDwoyhIO8kYg==", "dev": true, + "peer": true, "requires": { "@webassemblyjs/ast": "1.11.0", "@webassemblyjs/helper-buffer": "1.11.0", @@ -13958,6 +14044,7 @@ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.11.0.tgz", "integrity": "sha512-6L285Sgu9gphrcpDXINvm0M9BskznnzJTE7gYkjDbxET28shDqp27wpruyx3C2S/dvEwiigBwLA1cz7lNUi0kw==", "dev": true, + "peer": true, "requires": { "@webassemblyjs/ast": "1.11.0", "@webassemblyjs/helper-api-error": "1.11.0", @@ -13972,6 +14059,7 @@ "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.11.0.tgz", "integrity": "sha512-Fg5OX46pRdTgB7rKIUojkh9vXaVN6sGYCnEiJN1GYkb0RPwShZXp6KTDqmoMdQPKhcroOXh3fEzmkWmCYaKYhQ==", "dev": true, + "peer": true, "requires": { "@webassemblyjs/ast": "1.11.0", "@xtuc/long": "4.2.2" @@ -14015,13 +14103,15 @@ "version": "1.2.0", "resolved": "https://registry.npmjs.org/@xtuc/ieee754/-/ieee754-1.2.0.tgz", "integrity": "sha512-DX8nKgqcGwsc0eJSqYt5lwP4DH5FlHnmuWWBRy7X0NcaGR0ZtuyeESgMwTYVEtxmsNGY+qit4QYT/MIYTOTPeA==", - "dev": true + "dev": true, + "peer": true }, "@xtuc/long": { "version": "4.2.2", "resolved": "https://registry.npmjs.org/@xtuc/long/-/long-4.2.2.tgz", "integrity": "sha512-NuHqBY1PB/D8xU6s/thBgOAiAP7HOYDQ32+BFZILJ8ivkUkAHQnWfn6WhL79Owj1qmUnoN/YPhktdIoucipkAQ==", - "dev": true + "dev": true, + "peer": true }, "abab": { "version": "2.0.5", @@ -14043,7 +14133,8 @@ "version": "8.4.0", "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.4.0.tgz", "integrity": "sha512-ULr0LDaEqQrMFGyQ3bhJkLsbtrQ8QibAseGZeaSUiT/6zb9IvIkomWHJIvgvwad+hinRAgsI51JcWk2yvwyL+w==", - "dev": true + "dev": true, + "peer": true }, "ajv": { "version": "6.12.6", @@ -14686,7 +14777,8 @@ "version": "1.0.3", "resolved": "https://registry.npmjs.org/chrome-trace-event/-/chrome-trace-event-1.0.3.tgz", "integrity": "sha512-p3KULyQg4S7NIHixdwbGX+nFHkoBiA4YQmyWtjb8XngSKV124nJmRysgAeujbUVb15vh+RvFUfCPqU7rXk+hZg==", - "dev": true + "dev": true, + "peer": true }, "class-utils": { "version": "0.3.6", @@ -14928,7 +15020,8 @@ "version": "2.20.3", "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", - "dev": true + "dev": true, + "peer": true }, "commondir": { "version": "1.0.1", @@ -15123,6 +15216,12 @@ "which": "^2.0.1" } }, + "cuint": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/cuint/-/cuint-0.2.2.tgz", + "integrity": "sha1-QICG1AlVDCYxFVYZ6fp7ytw7mRs=", + "dev": true + }, "dargs": { "version": "6.1.0", "resolved": "https://registry.npmjs.org/dargs/-/dargs-6.1.0.tgz", @@ -15563,7 +15662,8 @@ "version": "0.6.0", "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-0.6.0.tgz", "integrity": "sha512-f8kcHX1ArhllUtb/wVSyvygoKCznIjnxhLxy7TCvIiMdT7fL4ZDTIKaadMe6eLvOXg6Wk02UeoFgUoZ2EKZZUA==", - "dev": true + "dev": true, + "peer": true }, "es-to-primitive": { "version": "1.2.1", @@ -15580,6 +15680,11 @@ "resolved": "https://registry.npmjs.org/es6-object-assign/-/es6-object-assign-1.1.0.tgz", "integrity": "sha1-wsNYJlYkfDnqEHyx5mUrb58kUjw=" }, + "esbuild": { + "version": "0.12.11", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.12.11.tgz", + "integrity": "sha512-h83GwI6lYOrnSv5hSY2i2XZ191v3haj2IGDzwrkfWHhuO/kVMX3RYjhwRNG9E5VSxVLPaUjTVwrv8HWLvhk2nQ==" + }, "escalade": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz", @@ -15603,6 +15708,7 @@ "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-5.1.1.tgz", "integrity": "sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw==", "dev": true, + "peer": true, "requires": { "esrecurse": "^4.3.0", "estraverse": "^4.1.1" @@ -15613,6 +15719,7 @@ "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz", "integrity": "sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==", "dev": true, + "peer": true, "requires": { "estraverse": "^5.2.0" }, @@ -15621,7 +15728,8 @@ "version": "5.2.0", "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.2.0.tgz", "integrity": "sha512-BxbNGGNm0RyRYvUdHpIwv9IWzeM9XClbOxwoATuFdOE7ZE6wHL+HQ5T8hoPM+zHvmKzzsEqhgy0GrQ5X13afiQ==", - "dev": true + "dev": true, + "peer": true } } }, @@ -15629,7 +15737,8 @@ "version": "4.3.0", "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-4.3.0.tgz", "integrity": "sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==", - "dev": true + "dev": true, + "peer": true }, "esutils": { "version": "2.0.3", @@ -16410,7 +16519,8 @@ "version": "0.4.1", "resolved": "https://registry.npmjs.org/glob-to-regexp/-/glob-to-regexp-0.4.1.tgz", "integrity": "sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw==", - "dev": true + "dev": true, + "peer": true }, "globals": { "version": "11.12.0", @@ -17337,6 +17447,7 @@ "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-27.0.2.tgz", "integrity": "sha512-EoBdilOTTyOgmHXtw/cPc+ZrCA0KJMrkXzkrPGNwLmnvvlN1nj7MPrxpT7m+otSv2e1TLaVffzDnE/LB14zJMg==", "dev": true, + "peer": true, "requires": { "@types/node": "*", "merge-stream": "^2.0.0", @@ -17347,13 +17458,15 @@ "version": "4.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true + "dev": true, + "peer": true }, "supports-color": { "version": "8.1.1", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", "dev": true, + "peer": true, "requires": { "has-flag": "^4.0.0" } @@ -17391,7 +17504,8 @@ "version": "1.0.2", "resolved": "https://registry.npmjs.org/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz", "integrity": "sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw==", - "dev": true + "dev": true, + "peer": true }, "json-parse-even-better-errors": { "version": "2.3.1", @@ -17473,7 +17587,8 @@ "version": "4.2.0", "resolved": "https://registry.npmjs.org/loader-runner/-/loader-runner-4.2.0.tgz", "integrity": "sha512-92+huvxMvYlMzMt0iIOukcwYBFpkYJdpl2xsZ7LrlayO7E8SOv+JJUEK17B/dJIHAOLMfh2dZZ/Y18WgmGtYNw==", - "dev": true + "dev": true, + "peer": true }, "loader-utils": { "version": "1.4.0", @@ -18149,7 +18264,8 @@ "version": "2.6.2", "resolved": "https://registry.npmjs.org/neo-async/-/neo-async-2.6.2.tgz", "integrity": "sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==", - "dev": true + "dev": true, + "peer": true }, "nice-try": { "version": "1.0.5", @@ -19243,6 +19359,7 @@ "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.0.0.tgz", "integrity": "sha512-6D82/xSzO094ajanoOSbe4YvXWMfn2A//8Y1+MUqFAJul5Bs+yn36xbK9OtNDcRVSBJ9jjeoXftM6CfztsjOAA==", "dev": true, + "peer": true, "requires": { "@types/json-schema": "^7.0.6", "ajv": "^6.12.5", @@ -19778,7 +19895,8 @@ "version": "2.0.1", "resolved": "https://registry.npmjs.org/source-list-map/-/source-list-map-2.0.1.tgz", "integrity": "sha512-qnQ7gVMxGNxsiL4lEuJwe/To8UnK7fAnmbGEEH8RpLouuKbeEm0lhbQVFIrNSuB+G7tVrAlVsZgETT5nljf+Iw==", - "dev": true + "dev": true, + "peer": true }, "source-map": { "version": "0.5.7", @@ -20140,6 +20258,7 @@ "resolved": "https://registry.npmjs.org/terser/-/terser-5.7.0.tgz", "integrity": "sha512-HP5/9hp2UaZt5fYkuhNBR8YyRcT8juw8+uFbAme53iN9hblvKnLUTKkmwJG6ocWpIKf8UK4DoeWG4ty0J6S6/g==", "dev": true, + "peer": true, "requires": { "commander": "^2.20.0", "source-map": "~0.7.2", @@ -20150,7 +20269,8 @@ "version": "0.7.3", "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.7.3.tgz", "integrity": "sha512-CkCj6giN3S+n9qrYiBTX5gystlENnRW5jZeNLHpe6aue+SrHcG5VYwujhW9s4dY31mEGsxBDrHR6oI69fTXsaQ==", - "dev": true + "dev": true, + "peer": true } } }, @@ -20159,6 +20279,7 @@ "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.1.3.tgz", "integrity": "sha512-cxGbMqr6+A2hrIB5ehFIF+F/iST5ZOxvOmy9zih9ySbP1C2oEWQSOUS+2SNBTjzx5xLKO4xnod9eywdfq1Nb9A==", "dev": true, + "peer": true, "requires": { "jest-worker": "^27.0.2", "p-limit": "^3.1.0", @@ -20172,7 +20293,8 @@ "version": "0.6.1", "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true + "dev": true, + "peer": true } } }, @@ -20715,6 +20837,7 @@ "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.2.0.tgz", "integrity": "sha512-up4YAn/XHgZHIxFBVCdlMiWDj6WaLKpwVeGQk2I5thdYxF/KmF0aaz6TfJZ/hfl1h/XlcDr7k1KH7ThDagpFaA==", "dev": true, + "peer": true, "requires": { "glob-to-regexp": "^0.4.1", "graceful-fs": "^4.1.2" @@ -20743,6 +20866,7 @@ "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.41.0.tgz", "integrity": "sha512-pCVO7hVm8XiL6DpPtXrFLS8ktmH/tpvtbEex6hn4RweTFe6z6Cugh5FlQoEPZotb15HiirjM2Kv7THTA7sKLzQ==", "dev": true, + "peer": true, "requires": { "@types/eslint-scope": "^3.7.0", "@types/estree": "^0.0.48", @@ -21412,6 +21536,7 @@ "resolved": "https://registry.npmjs.org/webpack-sources/-/webpack-sources-2.3.0.tgz", "integrity": "sha512-WyOdtwSvOML1kbgtXbTDnEW0jkJ7hZr/bDByIwszhWd/4XX1A3XMkrbFMsuH4+/MfLlZCUzlAdg4r7jaGKEIgQ==", "dev": true, + "peer": true, "requires": { "source-list-map": "^2.0.1", "source-map": "^0.6.1" @@ -21421,7 +21546,8 @@ "version": "0.6.1", "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true + "dev": true, + "peer": true } } }, @@ -21618,6 +21744,15 @@ "resolved": "https://registry.npmjs.org/xxhash-wasm/-/xxhash-wasm-0.4.1.tgz", "integrity": "sha512-sAaACjH5Th5O2Y1Pl6Mm03bHdie8htTm7ZG146by2ITXuxD1Ksx46ZEOYaDhtlCY3fHrmDfdvzTOGzO1R00COA==" }, + "xxhashjs": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/xxhashjs/-/xxhashjs-0.2.2.tgz", + "integrity": "sha512-AkTuIuVTET12tpsVIQo+ZU6f/qDmKuRUcjaqR+OIvm+aCBsZ95i7UVY5WJ9TMsSaZ0DA2WxoZ4acu0sPH+OKAw==", + "dev": true, + "requires": { + "cuint": "^0.2.2" + } + }, "y18n": { "version": "5.0.8", "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", diff --git a/package.json b/package.json index b480624b..7607af21 100644 --- a/package.json +++ b/package.json @@ -22,6 +22,7 @@ "browserify-zlib": "^0.2.0", "bson": "4.4.0", "cross-fetch": "^3.1.4", + "esbuild": "^0.12.11", "events": "^3.3.0", "int53": "^0.2.4", "lodash": "^4.17.21", @@ -44,7 +45,6 @@ "@types/chai": "^4.2.16", "@types/mocha": "^8.2.2", "@types/sinon": "^10.0.0", - "@webpack-cli/generators": "^2.2.0", "babel-loader": "^8.2.2", "babel-plugin-add-module-exports": "^1.0.4", "browserfs": "^1.4.3", @@ -60,16 +60,12 @@ "stream-browserify": "^3.0.0", "ts-loader": "^9.2.3", "ts-node": "^9.1.1", - "typescript": "^4.3.4", - "webpack": "~5.41.0", - "webpack-cli": "^4.7.2", - "webpack-dev-server": "^3.11.2" + "typescript": "^4.3.4" }, "scripts": { "build": "npm run build:node", "build:node": "tsc -b", - "build:browser": "webpack --mode=production --node-env=production", - "build:dev": "webpack --mode=development", + "build:browser": "esbuild ", "build:prod": "webpack --mode=production --node-env=production", "type": "tsc --noEmit", "lint": "echo 'Linting, it is on the TODO list...'", @@ -79,6 +75,16 @@ "thrift": "thrift -out gen-nodejs --gen js:ts parquet.thrift && thrift -out gen-nodejs --gen js:node parquet.thrift", "serve": "node wpserver.js" }, + "browser": { + "assert": "assert", + "events": "events", + "fs": "browserfs", + "path": "path-browserify", + "stream": "readable-stream", + "thrift": "./node_modules/thrift/lib/nodejs/lib/thrift/browser.js", + "util": "util", + "zlib": "browserify-zlib" + }, "engines": { "node": ">=14.16.0" }, diff --git a/test/integration.js b/test/integration.js index b7096fa1..9aca582e 100644 --- a/test/integration.js +++ b/test/integration.js @@ -476,7 +476,7 @@ describe('Parquet', function() { // const opts = { useDataPageV2: true, compression: 'LZO' }; // return writeTestFile(opts); // }); - + // // it('write a test file with LZO compression and then read it back', function() { // const opts = { useDataPageV2: true, compression: 'LZO' }; // return writeTestFile(opts).then(readTestFile); diff --git a/webpack.config.js b/webpack.config.js index 4a51adf3..b91aaafc 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -1,4 +1,10 @@ -// Generated using webpack-cli https://github.com/webpack/webpack-cli +/** + * Left here in case esbuild stops working for us when we try to re-enable + * LZO and Brotli, since it took a lot of time to get the right configuration + * Warning: this is much slower than esbuild. + * To use, you will need to re-install webpack, webpack-cli, source-map-loader. + * @type {path.PlatformPath | path} + */ const path = require('path'); const webpack = require("webpack") @@ -10,13 +16,13 @@ const BufferPlugin = new webpack.ProvidePlugin({ const processPlugin = new webpack.ProvidePlugin({ process: 'process/browser', }) let config = { - target: 'web', // should be default + target: 'web', // should be the default entry: './bootstrap.js', output: { path: path.resolve(__dirname), filename: "bundle.js", library: 'parquetjs', - wasmLoading: 'fetch', // should be default when target is 'web' + wasmLoading: 'fetch', // should be the default when target is 'web' }, devServer: { open: true, @@ -28,7 +34,7 @@ let config = { devtool: "source-map", experiments: { asyncWebAssembly: true, - // topLevelAwait: true + // topLevelAwait: true // maybe not needed? }, plugins: [ BufferPlugin, @@ -63,16 +69,8 @@ let config = { }, resolve: { extensions: ['.ts', '.js', '.wasm'], - // "browser": { - // "assert": "assert", - // "events": "events", - // "fs": "browserfs" - // "path": "path-browserify", - // "stream": "readable-stream", - // "thrift": "./node_modules/thrift/lib/nodejs/lib/thrift/browser.js", - // "util": "util", - // "zlib": "browserify-zlib", - // }, + // this uses a browser version of compression.js that + // currently does not include LZO or Brötli comprssion alias: { "./compression": "./browser/compression" },