1.0.8 • Published 9 years ago
base64_img-cli v1.0.8
base64_img-cli
Easy command convert img to base64
install
npm install base64_img-cli --saveconvert
trans -s <imgPath>##example
trans -s imgs/1.pnggenerate baseData.json
for html
trans i <imgPath> -j <html>restore
trans -r <html>####example
trans -r index.html
trans i imgs/1.png -j index.html
####before
<img src="imgs/1.png">####after
<img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACwAAAAcCAIA...">