WebSDK update from 2.0.171 to 2.0.180

sulphur

Member
Hi,

After updating of NPM package from 2.0.171 to 2.0.180 I have a strage errors that i dont have with 171 version.
I use following syntax tu import the Flashphoner object : import Flashphoner from '@flashphoner/websdk';

Here a the errors from console :

Code:
harmony module decorator:7 Uncaught (in promise) Error: ES Modules may not assign module.exports or exports.*, Use ESM export syntax, instead: ./node_modules/@flashphoner/websdk/src/room-module.js
    at Object.set [as exports] (harmony module decorator:7)
    at Module../node_modules/@flashphoner/websdk/src/room-module.js (room-module.js:545)
    at __webpack_require__ (bootstrap:19)
    at Module../node_modules/@flashphoner/websdk/src/flashphoner-core.js (flashphoner-core.js:2693)
    at __webpack_require__ (bootstrap:19)
    at Module../js/broadcast/flashphoner_engine.js (broadcaster.js:190)
    at __webpack_require__ (bootstrap:19)
    at Module../js/broadcast/broadcaster.js (js_broadcast_broadcaster_js-a1c79b20fb99777bbd20.js:14)
    at Function.__webpack_require__ (bootstrap:19)
Something changed about how we should include the Flashphoner object ?
 

sulphur

Member
it seems that update of uuid from 3.1.0 to 8.3.0 broke things
I have this error after updating from 2.0.171 to 2.0.173
 

Max

Administrator
Staff member
Good day.
it seems that update of uuid from 3.1.0 to 8.3.0 broke things
uuid developer strongly recommends to update, so other customers requested this.
So we raised the ticket WCS-3274 to change export syntax (and to check if this break anything else). As workaround, you can change it yourself locally from
Code:
module.exports = {
    connect: appSession,
    events: events
};
to
Code:
export {
    appSession as connect,
    events as events
}
 

Max

Administrator
Staff member
We fixed the syntax issue in Web SDK build 2.0.189, now using CommonJS syntax everywhere. The build is already available in NPM.
 
Top