Getting TypeError while integrating @zoomus/websdk in production

Description
I’m trying to integrate zoom in my create-react-app project. I’m using @zoomus/websdk. When I run my project on localhost, no error comes but the same code produces TypeError in production.

Error
80.d4a113db.chunk.js:1 Uncaught (in promise) TypeError: Super expression must either be null or a function, not undefined
at 80.d4a113db.chunk.js:1
at 80.d4a113db.chunk.js:1
at Object.e.exports (80.d4a113db.chunk.js:1)
at t (80.d4a113db.chunk.js:1)
at e.exports (80.d4a113db.chunk.js:1)
at Object.e.exports (80.d4a113db.chunk.js:1)
at n (80.d4a113db.chunk.js:1)
at Object.e.exports (80.d4a113db.chunk.js:1)
at n (80.d4a113db.chunk.js:1)
at Object.e.exports (80.d4a113db.chunk.js:1)

Error Screenshot

My Code
import {ZoomMtg} from ‘@zoomus/websdk’;
export function signature(meetConfig){
ZoomMtg.setZoomJSLib(‘node_modules/@zoomus/websdk/dist/lib’, ‘/av’);
ZoomMtg.preLoadWasm();
ZoomMtg.prepareJssdk();

let signature = ''
axios.post('http://localhost:8000/generate_signature/', {
    meetConfig
  })
  .then(result => {
    signature = result.data.text;
    if (result.data.text != ''){
      ZoomMtg.init({
        leaveUrl: meetConfig.leaveUrl,
        isSupportAV: true,
        success: function() {
          ZoomMtg.join({
            signature: signature,
            apiKey: 'xxx-xxx-xxx',
            meetingNumber: meetConfig.meetingNumber,
            userName: meetConfig.userName,
            userEmail: meetConfig.userEmail,
            success() {
              console.log("Success!!")
            },
            error(res) {
              console.log(res, 'in')
            }
          })
        },
        error(res) {
          console.log(res, 'out')
        }
      })
    }
})

}

Which Version?
@zoomus/websdk”: “^1.7.2”,
“react”: “^16.6.3”,
“react-dom”: “^16.6.3”,
“redux”: “^4.0.1”,
“redux-thunk”: “^2.3.0”,

Additional Context
If anyone is having any suggestion, please let me know.

Hey @abhishekkr1993, thanks for posting and using Zoom!

Can you see if this stack overflow helps as I think this could be an issue with a react version?

Here are also related posts with solutions:

https://devforum.zoom.us/search?q=Super%20expression%20must%20either%20be%20null

Thanks,
Tommy

Hey @tommy, thanks for the response. I was able to resolve my issue with the help of the above solutions.

Thanks,
Abhishek

1 Like

Great! Happy to hear you got it working! :slight_smile:

Thanks,
Tommy