summaryrefslogtreecommitdiff
path: root/impls
diff options
context:
space:
mode:
Diffstat (limited to 'impls')
-rw-r--r--impls/monero.ts/README.md10
-rw-r--r--impls/monero.ts/src/wallet.ts4
2 files changed, 12 insertions, 2 deletions
diff --git a/impls/monero.ts/README.md b/impls/monero.ts/README.md
index e3b20f6..773e8f6 100644
--- a/impls/monero.ts/README.md
+++ b/impls/monero.ts/README.md
@@ -7,10 +7,16 @@
This library does not ship with `monero_c` libraries.\
To use these bindings you have to bring your own `monero_c` libraries.\
There are at least two ways to do so:
+
- Ahead-of-time, during builds where you only ship necessary library for a given platform.\
- See [monero-tui](https://github.com/Im-Beast/monero-tui/blob/main/.github/workflows/dev-build.yml) build workflow as an example of doing so.
+ See [monero-tui](https://github.com/Im-Beast/monero-tui/blob/main/.github/workflows/dev-build.yml) build workflow as
+ an example of doing so.
```ts
- import { loadDylib, Wallet, WalletManager } from "https://raw.githubusercontent.com/MrCyjaneK/monero_c/master/impls/monero.ts/mod.ts";
+ import {
+ loadDylib,
+ Wallet,
+ WalletManager,
+ } from "https://raw.githubusercontent.com/MrCyjaneK/monero_c/master/impls/monero.ts/mod.ts";
// Try to load dylib from the default lib/* path
loadDylib();
diff --git a/impls/monero.ts/src/wallet.ts b/impls/monero.ts/src/wallet.ts
index 07c40ce..e3aae2e 100644
--- a/impls/monero.ts/src/wallet.ts
+++ b/impls/monero.ts/src/wallet.ts
@@ -19,6 +19,10 @@ export class Wallet {
this.sanitizer = sanitizer;
}
+ getPointer(): WalletPtr {
+ return this.#walletPtr;
+ }
+
async store(path = ""): Promise<boolean> {
const bool = await dylib.symbols.MONERO_Wallet_store(this.#walletPtr, CString(path));
await this.throwIfError();