Skip to content

Commit

Permalink
remove initSync
Browse files Browse the repository at this point in the history
  • Loading branch information
sentilesdal committed Nov 15, 2024
1 parent 548e863 commit eb485aa
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 38 deletions.
7 changes: 1 addition & 6 deletions apps/hyperdrive-trading/src/testing/setupTests.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,3 @@
import * as fixedPoint from "@delvtech/fixed-point-wasm";
import { beforeEach } from "vitest";

beforeEach(() => {
// This is safe to call multiple times. Internally it will return early if
// the WASM module has already been initialized.
fixedPoint.initSync(fixedPoint.wasmBuffer);
});
beforeEach(() => {});
2 changes: 0 additions & 2 deletions crates/hyperdrive-wasm/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@ npm i @delvtech/hyperdrive-wasm
```ts
import * as hyperwasm from "@delvtech/hyperdrive-wasm";

hyperwasm.initSync(hyperwasm.wasmBuffer);

const apr = hyperwasm.getFixedApr(poolInfo, poolConfig); // => '0.034999999999999999'
```

Expand Down
3 changes: 1 addition & 2 deletions packages/hyperdrive-js/src/hyperwasm.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
// eslint-disable-next-line import/no-unresolved
import * as hyperwasm from "@delvtech/hyperdrive-wasm";

hyperwasm.initSync(hyperwasm.wasmBuffer);

export { hyperwasm };
2 changes: 0 additions & 2 deletions packages/hyperdrive-wasm/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@ npm i @delvtech/hyperdrive-wasm
```ts
import * as hyperwasm from "@delvtech/hyperdrive-wasm";

hyperwasm.initSync(hyperwasm.wasmBuffer);

const apr = hyperwasm.getFixedApr(poolInfo, poolConfig); // => '0.034999999999999999'
```

Expand Down
28 changes: 2 additions & 26 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -6060,11 +6060,6 @@
resolved "https://registry.yarnpkg.com/@xtuc/long/-/long-4.2.2.tgz#d291c6a4e97989b5c61d9acf396ae4fe133a718d"
integrity sha512-NuHqBY1PB/D8xU6s/thBgOAiAP7HOYDQ32+BFZILJ8ivkUkAHQnWfn6WhL79Owj1qmUnoN/YPhktdIoucipkAQ==

[email protected]:
version "0.9.8"
resolved "https://registry.yarnpkg.com/abitype/-/abitype-0.9.8.tgz#1f120b6b717459deafd213dfbf3a3dd1bf10ae8c"
integrity sha512-puLifILdm+8sjyss4S+fsUN09obiT1g2YW6CtcQF+QDzxR0euzgEB29MZujC6zMk2a6SVmtttq1fc6+YFA7WYQ==

[email protected]:
version "1.0.0"
resolved "https://registry.yarnpkg.com/abitype/-/abitype-1.0.0.tgz#237176dace81d90d018bebf3a45cb42f2a2d9e97"
Expand Down Expand Up @@ -16852,16 +16847,11 @@ typedoc@^0.25.7:
minimatch "^9.0.3"
shiki "^0.14.7"

typescript@^5.0.2, typescript@^5.3.3, typescript@^5.4.4, typescript@^5.4.5, typescript@^5.5.4:
typescript@^5.0.2, typescript@^5.3.3, typescript@^5.4.4, typescript@^5.4.5, typescript@^5.5.4, typescript@~5.2.2:
version "5.5.4"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-5.5.4.tgz#d9852d6c82bad2d2eda4fd74a5762a8f5909e9ba"
integrity sha512-Mtq29sKDAEYP7aljRgtPOpTvOfbwRWlS6dPRzwjdE+C0R4brX/GUyhHSecbHMFLNBLcJIPt9nl9yG5TZ1weH+Q==

typescript@~5.2.2:
version "5.2.2"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-5.2.2.tgz#5ebb5e5a5b75f085f22bc3f8460fba308310fa78"
integrity sha512-mI4WrpHsbCIcwT9cF4FZvr80QUeKvsUsUvKDoR+X/7XHQH98xYD8YHZg7ANtz2GtZt/CBq2QJ0thkGJMHfqc1w==

ua-parser-js@^1.0.37:
version "1.0.37"
resolved "https://registry.yarnpkg.com/ua-parser-js/-/ua-parser-js-1.0.37.tgz#b5dc7b163a5c1f0c510b08446aed4da92c46373f"
Expand Down Expand Up @@ -17265,21 +17255,7 @@ vfile@^6.0.0, vfile@^6.0.1:
unist-util-stringify-position "^4.0.0"
vfile-message "^4.0.0"

viem@^1.0.0, viem@^1.1.4:
version "1.21.4"
resolved "https://registry.yarnpkg.com/viem/-/viem-1.21.4.tgz#883760e9222540a5a7e0339809202b45fe6a842d"
integrity sha512-BNVYdSaUjeS2zKQgPs+49e5JKocfo60Ib2yiXOWBT6LuVxY1I/6fFX3waEtpXvL1Xn4qu+BVitVtMh9lyThyhQ==
dependencies:
"@adraffy/ens-normalize" "1.10.0"
"@noble/curves" "1.2.0"
"@noble/hashes" "1.3.2"
"@scure/bip32" "1.3.2"
"@scure/bip39" "1.2.1"
abitype "0.9.8"
isows "1.0.3"
ws "8.13.0"

viem@^2.7.8, viem@^2.9.2:
[email protected], viem@^1.0.0, viem@^1.1.4, viem@^2.7.8, viem@^2.9.2:
version "2.9.2"
resolved "https://registry.yarnpkg.com/viem/-/viem-2.9.2.tgz#29bd2425222be136bf969a90dd3a8d6032221904"
integrity sha512-GRakUTNiYE9W+vL+Be9JkQfzWnkczerHtSpEe2JR/jEGTYZAs4shrA4WLgiaVCI9JxpnduZhQfRWNvy2dlyP2g==
Expand Down

0 comments on commit eb485aa

Please sign in to comment.