gpt4 book ai didi

javascript - hottowel undefined 不是一个函数

转载 作者:行者123 更新时间:2023-11-28 19:22:36 24 4
gpt4 key购买 nike

这是我第一次使用 Node.js

我正在关注本教程:http://www.johnpapa.net/get-up-and-running-with-node-and-visual-studio/

我使用 Cmder 作为命令提示符。

我已安装所有组件,并且可以查看以下版本: Node 新项目管理凉亭自耕农 gulp 咕噜声

当我尝试使用以下命令构建应用程序时: gulpserve-dev --sync 这是输出:

F:\Projects\myapp
λ gulp serve-dev --sync
[04:18:21] Using gulpfile F:\Projects\myapp\gulpfile.js
[04:18:21] Starting 'wiredep'...
[04:18:21] Wiring the bower dependencies into the html
[04:18:21] Starting 'clean-styles'...
[04:18:21] Cleaning: ./.tmp/**/*.css,./build/styles/**/*.css
[04:18:21] Starting 'clean-code'...
[04:18:21] Cleaning: ./.tmp/**/*.js,./build/js/**/*.js,./build/**/*.html
[04:18:21] Finished 'clean-styles' after 32 ms
[04:18:21] Starting 'styles'...
[04:18:21] Compiling Less --> CSS
[04:18:22] Finished 'clean-code' after 625 ms
[04:18:22] Starting 'templatecache'...
[04:18:22] Creating an AngularJS $templateCache
F:\Projects\myapp\node_modules\gulp-less\index.js:68
}).done(undefined, cb);
^
TypeError: undefined is not a function
at DestroyableTransform._transform (F:\Projects\myapp\node_modules\gulp-less\index.js:68:8)
at DestroyableTransform.Transform._read (F:\Projects\myapp\node_modules\gulp-less\node_modules\through2\node_modules\readable-stream\lib\_stream_transform.js:184:10)
at DestroyableTransform.Transform._write (F:\Projects\myapp\node_modules\gulp-less\node_modules\through2\node_modules\readable-stream\lib\_stream_transform.js:172:12)
at doWrite (F:\Projects\myapp\node_modules\gulp-less\node_modules\through2\node_modules\readable-stream\lib\_stream_writable.js:237:10)
at writeOrBuffer (F:\Projects\myapp\node_modules\gulp-less\node_modules\through2\node_modules\readable-stream\lib\_stream_writable.js:227:5)
at DestroyableTransform.Writable.write (F:\Projects\myapp\node_modules\gulp-less\node_modules\through2\node_modules\readable-stream\lib\_stream_writable.js:194:11)
at write (F:\Projects\myapp\node_modules\gulp-plumber\node_modules\through2\node_modules\readable-stream\lib\_stream_readable.js:623:24)
at flow (F:\Projects\myapp\node_modules\gulp-plumber\node_modules\through2\node_modules\readable-stream\lib\_stream_readable.js:632:7)
at DestroyableTransform.pipeOnReadable (F:\Projects\myapp\node_modules\gulp-plumber\node_modules\through2\node_modules\readable-stream\lib\_stream_readable.js:664:5)
at DestroyableTransform.emit (events.js:129:20)

知道我哪里出错了吗?

最佳答案

我也遇到了同样的问题。更改 package.json 文件中的 devDependency 版本会有所帮助。像这样设置版本:

"gulp-less": "^3.0.0",

"gulp-ng-annotate": "^0.5.2",

并运行npm update

关于javascript - hottowel undefined 不是一个函数,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/28524790/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com