简体   繁体   中英

amazon-ivs-web-broadcast - TypeError: Cannot read properties of undefined (reading 'bind')

Working with amazon-ivs-web-broadcast and running into the issue mentioned above when trying to create the IVSBroadcastClient

import IVSBroadcastClient from "amazon-ivs-web-broadcast";

let client = IVSBroadcastClient.create({
    streamConfig: IVSBroadcastClient.BASIC_LANDSCAPE,
    ingestEndpoint: streamConfigData?.stream_url,
})

Error message

Any ideas what may be causing this?

Tried passing hard coded values as arguments, and still running into the same error, so not sure what else could be causing this.

EDIT: This issue works fine on my local instance, but when it gets deployed to development, only then I am seeing the error mentioned.

I'm assuming that you are using React for this application (since I have seen this issue myself with React). If so, for now, you'll have to produce your production build with the following command:

npm run build -- --profile

To workaround an issue with the way function names are minified.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM