Some checks failed
full compatibility check / lib_mingw (monero) (push) Has been cancelled
full compatibility check / lib_mingw (peya) (push) Has been cancelled
full compatibility check / lib_mingw (salvium) (push) Has been cancelled
full compatibility check / lib_android (monero) (push) Has been cancelled
full compatibility check / lib_android (peya) (push) Has been cancelled
full compatibility check / lib_android (salvium) (push) Has been cancelled
full compatibility check / lib_linux (monero) (push) Has been cancelled
full compatibility check / lib_linux (peya) (push) Has been cancelled
full compatibility check / lib_linux (salvium) (push) Has been cancelled
full compatibility check / macos build (monero) (push) Has been cancelled
full compatibility check / macos build (peya) (push) Has been cancelled
full compatibility check / macos build (salvium) (push) Has been cancelled
full compatibility check / ios build (monero) (push) Has been cancelled
full compatibility check / ios build (peya) (push) Has been cancelled
full compatibility check / ios build (salvium) (push) Has been cancelled
full compatibility check / create single release file (push) Has been cancelled
full compatibility check / test ts library (push) Has been cancelled
full compatibility check / linux regression tests (monero) (push) Has been cancelled
full compatibility check / linux regression tests (peya) (push) Has been cancelled
full compatibility check / linux regression tests (salvium) (push) Has been cancelled
full compatibility check / macos regression tests (monero) (push) Has been cancelled
full compatibility check / macos regression tests (peya) (push) Has been cancelled
full compatibility check / macos regression tests (salvium) (push) Has been cancelled
full compatibility check / linux integration tests (monero) (push) Has been cancelled
full compatibility check / linux integration tests (peya) (push) Has been cancelled
full compatibility check / linux integration tests (salvium) (push) Has been cancelled
full compatibility check / macos integration tests (monero) (push) Has been cancelled
full compatibility check / macos integration tests (peya) (push) Has been cancelled
full compatibility check / macos integration tests (salvium) (push) Has been cancelled
full compatibility check / comment on pr (push) Has been cancelled
Build documentation / build (push) Has been cancelled
Check if dart bindings are in sync / android (push) Has been cancelled
Check if checksums are in sync / android (push) Has been cancelled
monero.ts
monero_c bindings for Deno.
Usage
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 build workflow as an example of doing so.import { loadMoneroDylib, 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 // You can also use loadWowneroDylib for Wownero loadMoneroDylib(); const wm = await WalletManager.new(); const wallet = await wm.createWallet("./my_wallet", "password"); console.log(await wallet.address()); await wallet.store(); - Just-in-time, where you download and cache the library at runtime.
You can use something like plug to achieve the result.import { dlopen } from "jsr:@denosaurs/plug"; // It's recommened to put the monero.ts github link into your import_map to reduce the url clutter import { loadMoneroDylib, symbols, Wallet, WalletManager } from "https://raw.githubusercontent.com/MrCyjaneK/monero_c/master/impls/monero.ts/mod.ts"; // Load dylib loaded by plug const lib = await dlopen(..., symbols); loadMoneroDylib(lib); const wm = await WalletManager.new(); const wallet = await wm.createWallet("./my_wallet", "password"); console.log(await wallet.address()); await wallet.store();