
Security News
npm Adopts OIDC for Trusted Publishing in CI/CD Workflows
npm now supports Trusted Publishing with OIDC, enabling secure package publishing directly from CI/CD workflows without relying on long-lived tokens.
gulp-processhtml
Advanced tools
Gulp plugin uses Denis Ciccale's node-htmlprocessor to process/transform html files.
npm install gulp-processhtml --save-dev
var gulp = require('gulp'),
processhtml = require('gulp-processhtml')
opts = { /* plugin options */ };
gulp.task('default', function () {
return gulp.src('./*.html')
.pipe(processhtml(opts))
.pipe(gulp.dest('dist'));
});
You might need to change some attributes in your html, when you're releasing for a different environment.
Using this plugin, you can transform this:
<!DOCTYPE html>
<html>
<head>
<!-- build:css style.min.css -->
<link rel="stylesheet" href="css/style.css">
<!-- /build -->
</head>
<body>
<!-- build:js app.min.js -->
<script src="app.js"></script>
<!-- /build -->
<!-- build:remove -->
<script src="http://192.168.0.1:35729/livereload.js?snipver=1"></script>
<!-- /build -->
<!-- build:replace 'Goodbye Livereload...' -->
<script src="http://192.168.0.1:35729/livereload.js?snipver=1"></script>
<!-- /build -->
</body>
</html>
To this:
<!DOCTYPE html>
<html>
<head>
<link rel="stylesheet" href="style.min.css">
</head>
<body>
<script src="app.min.js"></script>
Goodbye Livereload...
</body>
</html>
FAQs
Process html files at build time to modify them as you wish
The npm package gulp-processhtml receives a total of 1,192 weekly downloads. As such, gulp-processhtml popularity was classified as popular.
We found that gulp-processhtml 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
npm now supports Trusted Publishing with OIDC, enabling secure package publishing directly from CI/CD workflows without relying on long-lived tokens.
Research
/Security News
A RubyGems malware campaign used 60 malicious packages posing as automation tools to steal credentials from social media and marketing tool users.
Security News
The CNA Scorecard ranks CVE issuers by data completeness, revealing major gaps in patch info and software identifiers across thousands of vulnerabilities.