@ledgerhq/live-common
“Ledger Live Common” ````
`.--:::::
`.-::::::::: ````
.://///:-..`` `-/+++/-`
`://///-` -++++++o/.
`/+++/:` -+++++osss+`
`:++++:` ./++++-/osss/`
.+++++` `-://- .ooooo.
-+ooo/` `` `/oooo-
.oooo+` .::-.` `+++++.
`+oooo:./+++/. -++++/`
-ossso+++++:` -/+++/.
-ooo+++++:` .://///.
./+++++/` ``.-://///:`
`---.` -:::::///:-.
:::::::-.`
....``
Ledger Live Common (@ledgerhq/live-common
) is a JavaScript library available via a NPM package.
This library depends on a bunch of ledgerjs packages and put together the core business logic behind Ledger Live Desktop and Ledger Live Mobile.
The stack is pretty standard for a ES6 and FlowType library. The notable dependencies are libraries like RxJS and BigNumber.js. There is also a bit of React and Redux but exposed in agnostic ways (meaning it's not mandatory to use – there will be dedicated entry point for them to offer utilities like React Hooks).
Documentation
- Introduction, Goals and Tradeoffs
- Getting started
- Setup to use
@ledgerhq/live-common
ledger-live
CLI- tools web playground
mobile-test-app
test project
- Setup to use
- Learn by example
- The Currency models and utilities
- The Account models and portfolio logic
- The CurrencyBridge: scan accounts with a device
- The AccountBridge: synchronize an account and perform transaction
- Hardware Wallet logic
- Apps store logic
- Firmware Update logic
- Countervalues logic
- Coin integration specifics
- Introduction
- Bridge implementations, where to start? (JS, Libcore, Mock)
- Implementing the hardware wallet logic of a new coin
- The account derivation (BIP44 and exceptions)
- Advanced
- api/socket
createDeviceSocket
and script runner - env.js: live-common configuration system
- Serialization and reconciliation
- libcore typing and wrapping
- cross.js and "LiveQR" protocol
- cache.js helpers
- Tokens management and ERC20
- Developing with lib-ledger-core bindings
- api/socket
Developing with Ledger Live Common
- Developing setup
- The different test approaches
- Unit test of live-common logic
- End-to-end tests of the
ledger-live
command - Bridge dataset tests
- Providing mocks to implement UI tests