Attempting gulp build fails with TypeError
Here is the output from my shell after doing a clone locally and npm install && bower install:
$ gulp D:\Git\ui-select\node_modules\karma\node_modules\socket.io\lib\store.js:35 Store.prototype.proto = EventEmitter.prototype; ^
TypeError: Cannot read property 'prototype' of undefined
at Object.
I'm running windows 10, node v7.1.0
Is a specific version of node required?
am also getting the same error, I'm too running windows 10, node v7.1.0.
Root Cause : You must have installed latest node.js and where as your code is still using old node.js
Fix: 1.Go to your local cloned repo, delete the folder "node_modules" 2.Go to control panel -> add/remove programs -> locate the node.js and un install 3.go to https://nodejs.org/en/download/ and download the lower version of node.js and try
*** In my case I had installed v6.9.4 on my windows 10 and faced the above issue. When I re-installed v5.10.1 resolved the issue***
Hi @andrewmurray is this issue resolved with above comments?
Hi, yes it seems to be resolved on my current versions of node & npm, 6.10.0 and 4.1.1 respectively. I have gone back to the LTS versions for other non-associated reasons. I have also tried at home on the node 7.2 version and it seemed to work fine. Unfortunately, lots of tests fail following a gulp but I'll raise another ticket for those if my investigations get me nowhere.
Great so we can close down this issue?
Yeah, please do. Thanks.
It looks like karma package is throwing that error.
TypeError: Cannot read property 'prototype' of undefined at Object. (D:\Git\ui-select\node_modules\ karma \node_modules\socket.io\lib\store.js:35:41)
Rather than downgrading node version you can upgrade karma version to solve this issue
"jasmine-core": "latest",
"karma": "latest",
"karma-chrome-launcher": "latest",
"karma-jasmine": "latest"
@RohithKP its working nicely