<meta charset="utf-8" />
<meta lang="en" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
- <script type="module" src="https://cdn.jsdelivr.net/npm/barcode-detector@2.2.11/dist/es/side-effects.min.js"></script>
- <script type="module">
- let libnemo, css
- const barcodeDetector = new BarcodeDetector()
-
+ <!-- <script type="module" src="https://cdn.jsdelivr.net/npm/barcode-detector@2.2.11/dist/es/side-effects.min.js"></script> -->
+ <script type="module" src="https://cdn.jsdelivr.net/npm/libnemo@0.0.16/dist/global.min.js"></script>
+ <script type="module" src="./test.js"></script>
+ <script type="module" src="../libnemo/dist/global.min.js"></script>
+ <script>
+ // const barcodeDetector = new BarcodeDetector({
+ // formats: ["qr_code"],
+ // })
+ // const imageFile = await fetch(
+ // "https://api.qrserver.com/v1/create-qr-code/?size=150x150&data=Hello%20world!",
+ // ).then(resp => resp.blob())
+ // barcodeDetector.detect(imageFile).then(console.log)
+
+ // let css
const observer = new MutationObserver((mutations) => {
for (const mutation of mutations) {
if (mutation.type === "attributes") {
} catch (err) {
location.hash = '#transact'
}
- await loadNemo()
await loadData()
await loadUi()
console.log('done')
})
- async function loadNemo () {
- console.log('loading libnemo')
- libnemo = await import('https://cdn.jsdelivr.net/npm/libnemo@0.0.14/dist/main.min.js')
- const barcodeDetector = new BarcodeDetector({
- formats: ["qr_code"],
- })
- const imageFile = await fetch(
- "https://api.qrserver.com/v1/create-qr-code/?size=150x150&data=Hello%20world!",
- ).then(resp => resp.blob())
- barcodeDetector.detect(imageFile).then(console.log)
- }
-
async function loadData () {
console.log('loading data')
const walletSelect = document.querySelector('#wallet')
}
case '_ledger': {
try {
- await LedgerWallet.create()
+ await libnemo.LedgerWallet.create()
} catch (err) {
walletSelect.value = ''
console.error(err)