Comments (8)
gutil.File => https://www.npmjs.com/package/vinyl
gutil.replaceExtension => The .extname property on Vinyl objects or https://www.npmjs.com/package/replace-ext
gutil.colors => https://www.npmjs.com/package/ansi-colors
gutil.date => https://www.npmjs.com/package/date-format
gutil.log => https://www.npmjs.com/package/fancy-log
gutil.template => https://www.npmjs.com/package/lodash.template
gutil.env => https://www.npmjs.com/package/minimist
gutil.beep => https://www.npmjs.com/package/beeper
gutil.noop => https://www.npmjs.com/package/through2
gutil.isStream => Use the .isStream() method on Vinyl objects
gutil.isBuffer => Use the .isBuffer() method on Vinyl objects
gutil.isNull => Use the .isNull() method on Vinyl objects
gutil.linefeed => Use the string '\n' in your code
gutil.combine => https://www.npmjs.com/package/multipipe
gutil.buffer => https://www.npmjs.com/package/list-stream
gutil.PluginError => https://www.npmjs.com/package/plugin-error
from gulp-util.
@Spongman
noop
is equivalent to () => through2.obj()
. I agree it could be clearer. If you don't use the return value, an empty function should be enough. Calling noop
returns a pass-through stream in object mode.
I'll take some time during the week-end to compile a list of examples of common cases I encountered while helping other modules to migrate.
from gulp-util.
How about suggesting gulp-noop (github)?
Personally I'd prefer that a PassThrough stream was used directly, but I suppose it is implementation details.
from gulp-util.
I am a bit confused by the suggestion to replace gutil.buffer
with list-stream
. Seems like the more well known bl
or concat-stream
would be more applicable.
Edit: Oh, I guess bl
does not support objectMode, making it a non-starter.
from gulp-util.
Adding to this - there is no suggested replacement for gulp-decompress
I encountered it using Gatsby:
[email protected]
└─┬ [email protected]
└─┬ [email protected]
└─┬ [email protected]
└─┬ [email protected]
└─┬ [email protected]
└── [email protected]
from gulp-util.
@katekourbatova You are reading this issue incorrectly. This is about improving suggestions for changing plugins using gulp-util. The case you are displaying is that gulp-decompress needs to follow this advice.
Tools should not be replacing whole plugins because they in turn depend on gulp-util. The proper thing to do is have gulp-decompress replace their usage of gulp-util (which is already done kevva/gulp-decompress@d3fdff1).
So for this case specifically, someone in the dependency chain needs to upgrade a version so that a newer version of gulp-decompress is used.
from gulp-util.
@katekourbatova In fact, it looks like gatsby-plugin-sharp@next
solves your issue (though for some reason npm install is still showing the gulp-util deprecation notice, not sure why).
from gulp-util.
As a recent newcomer I found it frustrating to get a pointer to "though2" for noop.
I managed to make a couple of noops (a comment above helped) but not a friendly entry.
import through2 from 'through2'
import transfob from 'transfob';
async function noop2() {
return () => through2.obj()
}
async function noop1() {
transfob( function( file, enc, next ) {
next( null, file );
})
}
from gulp-util.
Related Issues (20)
- The README on npm doesn't have the deprecation note HOT 1
- [email protected]
- deprecated [email protected] used on [email protected] > [email protected] HOT 3
- deprecated [email protected] used on [email protected] HOT 1
- [email protected] deprecated HOT 2
- gulp
- Gulp throws assertion error after fixing gulp-util deprecation with gulp-cli HOT 2
- Error cannot find gulp-util after attempting to fix assertion issue HOT 2
- Cannot find module 'gulp-util' HOT 3
- remove gulp-util HOT 1
- ecosystem
- remove gulp-util HOT 1
- remove gulp-util
- remove gulp-util
- [email protected]: is deprecated
- Please run `npm deprecate` HOT 1
- remove gulp-util by replacing the API listed below
- Can not install gulp on my project via npm HOT 1
- Security vulnerability HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gulp-util.