Skip to content
This repository has been archived by the owner on Jun 27, 2022. It is now read-only.

Buffer is not defined in @ledgerhq/hw-transport-webusb #734

Open
goga-m opened this issue Dec 8, 2021 · 1 comment
Open

Buffer is not defined in @ledgerhq/hw-transport-webusb #734

goga-m opened this issue Dec 8, 2021 · 1 comment

Comments

@goga-m
Copy link

goga-m commented Dec 8, 2021

Hey there,

Using @ledgerhq/hw-transport-webusb in browser with vite and I get the Buffer is not defined error.

If I am not mistaken it seems that it's only used in https://github.com/LedgerHQ/ledgerjs/blob/master/packages/hw-transport-webusb/src/TransportWebUSB.ts#L208.

As this package is meant to be used in browser, was wondering if you see any issues using https://github.com/feross/buffer instead of trying to access Buffer globally so that consumers wouldn't be required to add polyfills.

Thanks in advance.

@goga-m goga-m changed the title Buffer is undefined in @ledgerhq/hw-transport-webusb Buffer is not defined in @ledgerhq/hw-transport-webusb Dec 8, 2021
@Kevingislason
Copy link

Yeah, basically same issue on my end

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
2 participants