1.0.0 • Published 8 years ago

gulp-image64 v1.0.0

Weekly downloads
14
License
MIT
Repository
github
Last release
8 years ago

gulp-image64

NPM version Build Status Dependencies

Convert and replace image-files within your DOM/HTML to base64-encoded data.

Example

gulpfile.js
var gulp = require('gulp');
var image64 = require('gulp-image64');

gulp.task('default', function () {
	gulp.src('index.html')
		.pipe(image64())
		.pipe(gulp.dest('path'));
});
index.html // Before...
<html>
	<head>
	</head>
	<body>
		<img src="sample.png" />
...
path/index.html // ...after:
<html>
	<head>
	</head>
	<body>
		<img src="data:image/png;base64,...">

...