There is a significant change in gulp 4.0 which leads to assertionerror
when using syntax of gulp 3. one such change is the way tasks are defined. Instead of list parameters, gulp 4.0+ uses gulp.series()
and gulp.parallel()
. Using otherwise can lead to AssertionError: Task function must be specified.
Code Example
The below code will create assertionerror –
gulp.task('default', ['task1', 'task2','task3']);
Replace it with this –
gulp.task('default', gulp.series('task1', 'task2','task3'));