@hpcc-js/wasm-zstd 1.0.1 → 1.1.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/package.json CHANGED
@@ -1,58 +1,58 @@
1
1
  {
2
- "name": "@hpcc-js/wasm-zstd",
3
- "version": "1.0.1",
4
- "description": "hpcc-js - WASM zstd",
5
- "type": "module",
6
- "exports": {
7
- ".": {
8
- "types": "./types/index.d.ts",
9
- "import": "./dist/index.js"
10
- }
11
- },
12
- "types": "./types/index.d.ts",
13
- "files": [
14
- "dist/**/*",
15
- "src/**/*",
16
- "types/**/*"
17
- ],
18
- "scripts": {
19
- "clean": "rimraf ./dist ./dist-test ./types",
20
- "build-types": "tsc --project tsconfig.json --emitDeclarationOnly",
21
- "build-types-watch": "npm run build-types -- --watch",
22
- "build-ts": "node esbuild.mjs",
23
- "build-ts-dev": "npm run build-ts -- --mode=development",
24
- "build-ts-watch": "npm run compile-ts-dev -- --watch",
25
- "build-dev": "run-p build-types build-ts-dev",
26
- "build": "run-p build-types build-ts",
27
- "lint-skypack": "npx -y @skypack/package-check",
28
- "lint-eslint": "eslint src/**/*.ts",
29
- "lint": "run-p lint-eslint lint-skypack",
30
- "test-chrome": "karma start --single-run --browsers ChromiumHeadless karma.conf.cjs",
31
- "test-firefox": "karma start --single-run --browsers Firefox karma.conf.cjs",
32
- "test-node": "mocha ./dist-test/index.node.js --reporter spec",
33
- "test": "run-s test-chrome test-node"
34
- },
35
- "dependencies": {
36
- "yargs": "17.7.2"
37
- },
38
- "devDependencies": {
39
- "@hpcc-js/esbuild-plugins": "^1.0.1"
40
- },
41
- "keywords": [
42
- "graphviz",
43
- "typescript",
44
- "webassembly",
45
- "wasm",
46
- "dot",
47
- "neato",
48
- "twopi"
49
- ],
50
- "author": "hpcc-systems",
51
- "repository": {
52
- "type": "git",
53
- "url": "git+https://github.com/hpcc-systems/hpcc-js-wasm.git"
54
- },
55
- "homepage": "https://hpcc-systems.github.io/hpcc-js-wasm/",
56
- "license": "Apache-2.0",
57
- "gitHead": "4a93a0ee7a7100d8251f1190628d0511ab4bbb1a"
2
+ "name": "@hpcc-js/wasm-zstd",
3
+ "version": "1.1.0",
4
+ "description": "hpcc-js - WASM zstd",
5
+ "type": "module",
6
+ "exports": {
7
+ ".": {
8
+ "types": "./types/index.d.ts",
9
+ "default": "./dist/index.js"
10
+ }
11
+ },
12
+ "main": "./dist/index.js",
13
+ "types": "./types/index.d.ts",
14
+ "files": [
15
+ "dist/**/*",
16
+ "src/**/*",
17
+ "types/**/*"
18
+ ],
19
+ "scripts": {
20
+ "clean": "rimraf ./dist ./dist-test ./types",
21
+ "build-types": "tsc --project tsconfig.json --emitDeclarationOnly",
22
+ "build-types-watch": "npm run build-types -- --watch",
23
+ "build-ts": "node esbuild.mjs",
24
+ "build-ts-dev": "npm run build-ts -- --mode=development",
25
+ "build-ts-watch": "npm run compile-ts-dev -- --watch",
26
+ "build-dev": "run-p build-types build-ts-dev",
27
+ "build": "run-p build-types build-ts",
28
+ "lint-skypack": "npx -y @skypack/package-check",
29
+ "lint-eslint": "eslint src/**/*.ts",
30
+ "lint": "run-p lint-eslint",
31
+ "test-chrome": "karma start --single-run --browsers ChromiumHeadless karma.conf.cjs",
32
+ "test-firefox": "karma start --single-run --browsers Firefox karma.conf.cjs",
33
+ "test-node": "mocha ./dist-test/index.node.js --reporter spec",
34
+ "test": "run-s test-chrome test-node",
35
+ "update": "npx -y npm-check-updates -u -t minor",
36
+ "update-major": "npx -y npm-check-updates -u"
37
+ },
38
+ "devDependencies": {
39
+ "@hpcc-js/esbuild-plugins": "1.0.7"
40
+ },
41
+ "keywords": [
42
+ "graphviz",
43
+ "typescript",
44
+ "webassembly",
45
+ "wasm",
46
+ "dot",
47
+ "neato",
48
+ "twopi"
49
+ ],
50
+ "author": "hpcc-systems",
51
+ "repository": {
52
+ "type": "git",
53
+ "url": "git+https://github.com/hpcc-systems/hpcc-js-wasm.git"
54
+ },
55
+ "homepage": "https://hpcc-systems.github.io/hpcc-js-wasm/",
56
+ "license": "Apache-2.0",
57
+ "gitHead": "841d4713a5ccd8644024e27f929cbb63ffff0573"
58
58
  }
package/src/zstd.ts CHANGED
@@ -1,5 +1,5 @@
1
- // @ts-ignore
2
- import load, { reset } from "../../../build/src-cpp/zstd/zstdlib.wasm";
1
+ // @ts-expect-error importing from a wasm file is resolved via a custom esbuild plugin
2
+ import load, { reset } from "../../../build/packages/zstd/src-cpp/zstdlib.wasm";
3
3
  import { WasmLibrary } from "./wasm-library.ts";
4
4
 
5
5
  // Ref: http://facebook.github.io/zstd/zstd_manual.html
@@ -13,7 +13,7 @@ let g_zstd: Promise<Zstd>;
13
13
  * See [Zstandard](https://facebook.github.io/zstd/) for more details.
14
14
  *
15
15
  * ```ts
16
- * import { Zstd } from "@hpcc-js/wasm/zstd";
16
+ * import { Zstd } from "@hpcc-js/wasm-zstd";
17
17
  *
18
18
  * const zstd = await Zstd.load();
19
19
  *
package/types/zstd.d.ts CHANGED
@@ -5,7 +5,7 @@ import { WasmLibrary } from "./wasm-library.ts";
5
5
  * See [Zstandard](https://facebook.github.io/zstd/) for more details.
6
6
  *
7
7
  * ```ts
8
- * import { Zstd } from "@hpcc-js/wasm/zstd";
8
+ * import { Zstd } from "@hpcc-js/wasm-zstd";
9
9
  *
10
10
  * const zstd = await Zstd.load();
11
11
  *