imgurify
Browserify tranform to turn images into base64 data uri
Last updated 2 years ago by asbjornenge .
BSD · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install imgurify 
SYNC missed versions from official npm registry.

imgurify

Browserify transform that allows you to require images -> base64* data uri's.

* base64 only for raster images, svgs are inlined as svg+xml, because reasons...

Install

npm install --save imgurify

Use

browserify -t imgurify entry.js
var pony = require('./graphics/pony.png')
console.log(pony)
// => data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADcA...

Changelog

2.0.1

  • Improve SVG encoding - thanks felthy :tada:

2.0.0

  • Total rewrite
  • Reading files "manually" becuase weird browserify buffer behaviour (hoping to revert this back in the future)

1.2.2

  • Fixed incorrect mimetype for jpg

1.2.1

  • Fixed base64 encoding of large (multibuffer) raster images

1.2.0

  • Added a cli imgurify path/to/img.svg > img.js :heart_eyes:

1.1.0

  • Support for svg

1.0.0

  • Initial release :tada:

enjoy.

Current Tags

  • 2.0.1                                ...           latest (2 years ago)

9 Versions

  • 2.0.1                                ...           2 years ago
  • 2.0.0                                ...           4 years ago
  • 1.2.2                                ...           5 years ago
  • 1.2.1                                ...           5 years ago
  • 1.2.0                                ...           5 years ago
  • 1.1.0                                ...           5 years ago
  • 1.0.2                                ...           5 years ago
  • 1.0.1                                ...           5 years ago
  • 1.0.0                                ...           5 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (3)
Dev Dependencies (3)

Copyright 2014 - 2016 © taobao.org |