generator-ng-poly
generator-ng-poly copied to clipboard
Getting TypeError: _.invokeMap is not a function when trying to generate services, modules...
I'm working on a long-time project using this generator, and lately I'm getting this error when trying to create a new service/module/directive... etc:
_.invokeMap(this._composedWith, 'run');
^
TypeError: _.invokeMap is not a function
at child.run (/home/jeff/workspace/jarvis/jarvis/node_modules/yeoman-generator/lib/base.js:496:5)
at Environment.run (/home/jeff/.nvm/versions/node/v6.5.0/lib/node_modules/yo/node_modules/yeoman-environment/lib/environment.js:377:20)
at /home/jeff/.nvm/versions/node/v6.5.0/lib/node_modules/yo/lib/cli.js:140:11
at Array.forEach (native)
at /home/jeff/.nvm/versions/node/v6.5.0/lib/node_modules/yo/lib/cli.js:139:9
at Environment.resolver.lookup (/home/jeff/.nvm/versions/node/v6.5.0/lib/node_modules/yo/node_modules/yeoman-environment/lib/resolver.js:50:12)
at init (/home/jeff/.nvm/versions/node/v6.5.0/lib/node_modules/yo/lib/cli.js:115:7)
at pre (/home/jeff/.nvm/versions/node/v6.5.0/lib/node_modules/yo/lib/cli.js:73:3)
at Object.<anonymous> (/home/jeff/.nvm/versions/node/v6.5.0/lib/node_modules/yo/lib/cli.js:194:3)
I have NVM installed and I tried with different node versions (5.0.0, 6.5.0) so I don't know what happens.
I've tried in another different computers with fresh node and yeoman installs and the same error pops up.
Any ideas?
Hmm. Does using yo ng-poly:service a --module=home
, etc. work? I'll try to look into this tonight.
Hi @dustinspecker. No, I get the same error... Right now I'm trying with Node 6.5.0 and npm 3.10.3.
Hi again @dustinspecker, have you seen anything new about this?
Really sorry, I forgot about this.
I'm unable to reproduce this so far. During the initial project creation are there any Bower or npm errors?
I tried with Node 6.5.0 (with nvm), npm 3.10.3, yo 1.8.5, and ng-poly 13.0.0.
EDIT: Make sure yo is up-to-date. I believe there were some big changes with it when yeoman updated a bit ago.
Have you been able to try anything further?