Security News
tea.xyz Spam Plagues npm and RubyGems Package Registries
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
gulp-jsfmt
Advanced tools
Readme
Install via npm:
npm install gulp-jsfmt --save-dev
var gulp = require('gulp');
var jsfmt = require('gulp-jsfmt');
gulp.task('default', function() {
gulp.src('./**/*.js')
.pipe(jsfmt.rewrite('_.each(a, b) -> a.forEach(b)', '_.reduce(a, b, c) -> a.reduce(b, c)'))
.pipe(gulp.dest('./dist'));
});
var gulp = require('gulp');
var jsfmt = require('gulp-jsfmt');
var through = require('through2');
gulp.task('default', function() {
gulp.src('./**/*.js')
.pipe(jsfmt.search('_.each(a, b)', '_.reduce(a, b, c)'))
.pipe(through.obj(file, _, cb) {
file.matches.forEach(function(matches, wildcards) {
console.log(wildcards.z);
});
})
});
Formats js (not JSON) files
var gulp = require('gulp');
var jsfmt = require('gulp-jsfmt');
gulp.task('default', function() {
gulp.src('./**/*.js')
.pipe(jsfmt.format())
.pipe(gulp.dest('./dist'));
});
Formats json (not JS) files
var gulp = require('gulp');
var jsfmt = require('gulp-jsfmt');
gulp.task('default', function() {
gulp.src('./**/*.json')
.pipe(jsfmt.formatJSON())
.pipe(gulp.dest('./dist'));
});
matches
Each patterns specified will be used to call jsfmt.search
, and the results are passed back in the property named matches
in each of the Vinyl
object in the stream.
v0.1.0
expose search
function
v0.0.1
expose rewrite
function
MIT
FAQs
`gulp` task for `jsfmt`
The npm package gulp-jsfmt receives a total of 2 weekly downloads. As such, gulp-jsfmt popularity was classified as not popular.
We found that gulp-jsfmt demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
Security News
As cyber threats become more autonomous, AI-powered defenses are crucial for businesses to stay ahead of attackers who can exploit software vulnerabilities at scale.
Security News
UnitedHealth Group disclosed that the ransomware attack on Change Healthcare compromised protected health information for millions in the U.S., with estimated costs to the company expected to reach $1 billion.