【问题标题】:getting error 'assetmanager.process is not a function' while trying to start node server尝试启动节点服务器时出现错误“assetmanager.process 不是函数”
【发布时间】:2016-03-10 14:17:46
【问题描述】:

我正在尝试运行 MEAN 堆栈,我正在尝试通过运行 node server 命令来启动 Node 服务器,

`TypeError:assetmanager.process 不是函数 在 configureApp (C:\Users\Harsh\first\node_modules\meanio\lib\core_modules\module\aggregation.js:401:29) 在 Consumer.Dependable.runAction (C:\Users\Harsh\first\node_modules\lazy-dependable\index.js:73:22) 在 Consumer.Dependable.fire (C:\Users\Harsh\first\node_modules\lazy-dependable\index.js:70:53) 在 Consumer.onResolved (C:\Users\Harsh\first\node_modules\lazy-dependable\index.js:120:8) 在 Consumer.Dependable.resolve (C:\Users\Harsh\first\node_modules\lazy-dependable\index.js:56:10) 在 Meanio.Container.notifyResolved (C:\Users\Harsh\first\node_modules\lazy-dependable\index.js:209:7) 在 Dependency.onResolved (C:\Users\Harsh\first\node_modules\lazy-dependable\index.js:105:18) 在 Dependency.Dependable.resolve (C:\Users\Harsh\first\node_modules\lazy-dependable\index.js:56:10) 在 Meanio.Container.register (C:\Users\Harsh\first\node_modules\lazy-dependable\index.js:167:5) 在 C:\Users\Harsh\first\node_modules\meanio\lib\core_modules\db\index.js:101:20 打开时(C:\Users\Harsh\first\node_modules\mongoose\lib\connection.js:488:17) 在 NativeConnection.Connection.onOpen (C:\Users\Harsh\first\node_modules\mongoose\lib\connection.js:498:5) 在 C:\Users\Harsh\first\node_modules\mongoose\lib\connection.js:457:10 在 C:\Users\Harsh\first\node_modules\mongoose\lib\drivers\node-mongodb-native\connection.js:60:5 在 C:\Users\Harsh\first\node_modules\mongodb\lib\db.js:229:5 在 connectHandler (C:\Users\Harsh\first\node_modules\mongodb\lib\server.js:279:7) 在 g (events.js:260:16) 在 emitOne (events.js:77:13) 在发出 (events.js:169:7) 在 C:\Users\Harsh\first\node_modules\mongodb-core\lib\topologies\server.js:409:23 在 C:\Users\Harsh\first\node_modules\mongodb-core\lib\topologies\server.js:778:13 在 Callbacks.emit (C:\Users\Harsh\first\node_modules\mongodb-core\lib\topologies\server.js:95:3) C:\Users\Harsh\first\node_modules\mongodb\lib\server.js:282 process.nextTick(function() { throw err; }) ^

TypeError:assetmanager.process 不是函数 在 configureApp (C:\Users\Harsh\first\node_modules\meanio\lib\core_modules\module\aggregation.js:401:29) 在 Consumer.Dependable.runAction (C:\Users\Harsh\first\node_modules\lazy-dependable\index.js:73:22) 在 Consumer.Dependable.fire (C:\Users\Harsh\first\node_modules\lazy-dependable\index.js:70:53) 在 Consumer.onResolved (C:\Users\Harsh\first\node_modules\lazy-dependable\index.js:120:8) 在 Consumer.Dependable.resolve (C:\Users\Harsh\first\node_modules\lazy-dependable\index.js:56:10) 在 Meanio.Container.notifyResolved (C:\Users\Harsh\first\node_modules\lazy-dependable\index.js:209:7) 在 Dependency.onResolved (C:\Users\Harsh\first\node_modules\lazy-dependable\index.js:105:18) 在 Dependency.Dependable.resolve (C:\Users\Harsh\first\node_modules\lazy-dependable\index.js:56:10) 在 Meanio.Container.register (C:\Users\Harsh\first\node_modules\lazy-dependable\index.js:167:5) 在 C:\Users\Harsh\first\node_modules\meanio\lib\core_modules\db\index.js:101:20 打开时(C:\Users\Harsh\first\node_modules\mongoose\lib\connection.js:488:17) 在 NativeConnection.Connection.onOpen (C:\Users\Harsh\first\node_modules\mongoose\lib\connection.js:498:5) 在 C:\Users\Harsh\first\node_modules\mongoose\lib\connection.js:457:10 在 C:\Users\Harsh\first\node_modules\mongoose\lib\drivers\node-mongodb-native\connection.js:60:5 在 C:\Users\Harsh\first\node_modules\mongodb\lib\db.js:229:5 在 connectHandler (C:\Users\Harsh\first\node_modules\mongodb\lib\server.js:279:7) 在 g (events.js:260:16) 在 emitOne (events.js:77:13) 在发出 (events.js:169:7) 在 C:\Users\Harsh\first\node_modules\mongodb-core\lib\topologies\server.js:409:23 在 C:\Users\Harsh\first\node_modules\mongodb-core\lib\topologies\server.js:778:13 在 Callbacks.emit (C:\Users\Harsh\first\node_modules\mongodb-core\lib\topologies\server.js:95:3)

还用gulp命令还是同样的错误,我哪里错了??

【问题讨论】:

    标签: node.js mean-stack mean.io


    【解决方案1】:

    当 git clone 出现问题时出现类似错误。重新克隆存储库,然后在您的控制台上运行:

    git clone https://github.com/meanjs/mean.git myprojectname
    npm install
    bower install
    

    安装过程需要一点时间,但在此之后运行gulp 应该可以工作。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2012-06-05
      • 1970-01-01
      • 1970-01-01
      • 2018-12-15
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多