250 questions
1
vote
1
answer
47
views
gulp-uglify expects an object, non-object provided
I have an old project and have to add a filter to remove an item from the array of objects if the condition is true. I am getting the below error when trying to run gulp build.
[14:44:03] Using ...
1
vote
1
answer
101
views
Gulp don't create sourcemaps
I'm studying Gulp and trying to generate sourcemaps for my JavaScript file app.js, but sourcemaps generation isn't working as expected. I came across some old answers suggesting using the gulp-...
3
votes
1
answer
2k
views
gulp generates TypeError: The Streams property must be of type function
I got an error TypeError: The "streams[stream.length - 1]" property must be of type function. Received an instance of Pumpify while trying to minify a javascript using gulp package ,
Using ...
-2
votes
1
answer
175
views
How use Angular gulp uglify?
gulp.task("uglify", function () {
return (
gulp
.src("dist/alparslan-oto/main.js")
.pipe(rename("main.js"))
.pipe(sourcemaps.init())
.pipe(...
1
vote
1
answer
124
views
gulp-uglify causes constructor.name misbehaviour
In my gulpfile.js if I comment this line
.pipe(uglify({ preserveComments: 'some'}))
then my code is not looking ugly and for following line of code everything is working fine.
if(Mystudy.constructor....
0
votes
1
answer
786
views
How to Uglify Javascript with Liquid inline(s) - Shopify
So today I learnt that minimising JavaScript inside of js.liquid file is a nightmare.
I'm building with gulp & typescript:
This is a call from my entry TypeScript file that uses a liquid inline:
...
0
votes
0
answers
224
views
Gulp not compile strings with backticks
I have a problem with my gulp file. It is compile all correctly, except the strings with backticks. Is there some package or solution to fix that?
This is my gulpfile.js code:
const gulp = require('...
0
votes
1
answer
230
views
How can I use Gulp build vue component tag in the javescript file
I want use Gulp build the file is a javescript. the file was imported to the Vue files.
The target code like this:
export const myOrderTable = (h, _this) => {
return [
{
title: 'orderNo',
...
0
votes
0
answers
59
views
GulpUglifyError - filter function jQuery
I have the following code but when I try to build it, I get this error:
events.js:174
throw er; // Unhandled 'error' event
^
GulpUglifyError: unable to minify JavaScript
This is my code:
$('.wp-block-...
1
vote
2
answers
758
views
script files not loading in rev-manifest.json (gulp)
I have this gulpfile.js where I'm minifying my js files the problem is that when I'm doing gulp build this task is creating the minified js files but not entering the key-value pairs in the rev-...
0
votes
2
answers
1k
views
gulpfile.js is not run on Azure VSBuild
I have a .NET MVC project that executes the gulpfile.js after each build /// <binding AfterBuild='default' />. This works well if I build the project locally in Visual Studio. But I have to set ...
4
votes
0
answers
115
views
Gulp re-processes unchanged files
I'm experiencing long (~30s) rebuilds of several of my gulp tasks. I'm first transpiling using babel, then uglifying and finally concatenating the respective files.
I determined that most of the time ...
0
votes
1
answer
208
views
Why is Gulp concatenating my output in the wrong order?
As shown in the following gulpfile.js, I am trying to compile jQuery, bootstrap.js, and a collection of Javascript snippets from a subfolder into a single app.js output file. It is working, except ...
6
votes
0
answers
626
views
Any Node.js Minifier supports Javascript Null-Coalescing operator (??)? [closed]
I am trying to minify javascript code, which contains many instances of the null-coalescing operator (??), however they all seem to throw Unexpected token: operator (?) error when parsing lines ...
0
votes
1
answer
117
views
gulp duplicating tasks in the terminal
I have a problem with my gulp, I don't know how to explain it, but you will understand the problem when you see it, basically, I think my gulp is duplicating the task and therefore the execution can ...