Intel® Collaboration Suite for WebRTC
Community support and discussions on the Intel® Collaboration Suite for WebRTC (Intel® CS for WebRTC).
Announcements
Intel Customer Support will be observing the Martin Luther King holiday on Monday, Jan. 17, and will return on Tues. Jan. 18.
For the latest information on Intel’s response to the Log4j/Log4Shell vulnerability, please see Intel-SA-00646

JS SDK 4.0 require failed

Bikbaev__Timur1
Beginner
155 Views

Ive download JS SDK 4.0 and put it on simple script:

/*global require, __dirname, console, process*/
'use strict';
var N = require('./ics')

 

But when im trying to run this script i have an error:

node test.js
/home/ubuntu/Release-v4.0/extras/tcast-conference-server-nodejs/ics.js:9
!function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this).Ics=e()}}(function(){return function(){return function e(t,n,i){function r(a,s){if(!n){if(!t){var c="function"==typeof require&&require;if(!s&&c)return c(a,!0);if(o)return o(a,!0);var u=new Er...={exports:{}};t[0].call(d.exports,function(e){return r(t[1]||e)},d,d.exports,e,t,n,i)}return n.exports}for(var o="function"==typeof require&&require,a=0;a<i.length;a++)r(i);return r}}()({1:[function(e,t,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});n.B...

ReferenceError: window is not defined
    at /home/ubuntu/Release-v4.0/extras/tcast-conference-server-nodejs/ics.js:9:5400
    at Object.5 (/home/ubuntu/Release-v4.0/extras/tcast-conference-server-nodejs/ics.js:9:5753)
    at r (/home/ubuntu/Release-v4.0/extras/tcast-conference-server-nodejs/ics.js:9:556)
    at /home/ubuntu/Release-v4.0/extras/tcast-conference-server-nodejs/ics.js:9:590
    at Object.7../logger.js (/home/ubuntu/Release-v4.0/extras/tcast-conference-server-nodejs/ics.js:9:6904)
    at r (/home/ubuntu/Release-v4.0/extras/tcast-conference-server-nodejs/ics.js:9:556)
    at /home/ubuntu/Release-v4.0/extras/tcast-conference-server-nodejs/ics.js:9:590
    at Object.4../mediaformat.js (/home/ubuntu/Release-v4.0/extras/tcast-conference-server-nodejs/ics.js:9:4650)
    at r (/home/ubuntu/Release-v4.0/extras/tcast-conference-server-nodejs/ics.js:9:556)
    at /home/ubuntu/Release-v4.0/extras/tcast-conference-server-nodejs/ics.js:9:590

 

Did i need to install something or i just miss something? ( ive checked with prev version(3.5.2, nuve.js) - everything works fine)

0 Kudos
4 Replies
Bikbaev__Timur1
Beginner
155 Views

adapter.js and socket.io.js added to script - same error

Qiujiao_W_Intel
Employee
155 Views

Did you run your code in browsers? As the error showed Windows is defined in browser and it cannot be found in your environment

Bikbaev__Timur1
Beginner
155 Views

nope, ive tried run this script on server with "node" command ( previous version = nuve.js) is working fine. Reason why im not using browser cuase we already have our custom app  and we want to upgrade it to ver.4

Qiujiao_W_Intel
Employee
155 Views

Hi, how do you use nuve.js in 3.5? to manage room related resources? If so you can use rest.js in 4.0, please refer to our document.

Reply