ResaleAI / receipt-components

A library to let you build receipts once and print them anywhere.
MIT License
4 stars 0 forks source link

Can not register receipt-image-browser node to a component #5

Closed FouadRaheb closed 8 months ago

FouadRaheb commented 8 months ago

When registering imagePlugin node to a component

import imagePlugin from "@resaleai/receipt-image-browser"; ReceiptComponent.registerNodes([imagePlugin]);

The page is throwing an error

⨯ file:///.../node_modules/@resaleai/receipt-image-browser/dist/main.mjs:11 import { bytes, charToByte } from "@resaleai/receipt-escpos-renderer/util"; ^^^^^ SyntaxError: The requested module '@resaleai/receipt-escpos-renderer/util' does not provide an export named 'bytes'

zaviermiller commented 8 months ago

Thanks for the report! I have made a PR to fix this issue and will merge it soon. I'll let you know when it's merged so you can update the version of the receipt-image-browser package you are using.

FouadRaheb commented 8 months ago

Thanks for the fast fix! Great work on this library, exactly what I needed for my project.

zaviermiller commented 8 months ago

This issue is now fixed in version receipt-components@3.3.1 and receipt-image-browser@1.1.1