image-compared
v1.0.0
Published
image remove repeat
Downloads
2
Readme
image-compared
remove repeat image
Usage
npm i image-compared
Methods
- compareImages
- removeDuplicateImages
1、Compare whether two images are the same.
const imageCompare = require("image-compared");
imageCompare.compareImages("image1.jpg", "image2.jpg").then((isSame) => {
console.log(isSame ? `They are the same` : "They are different");
});
2、Delete duplicate images in the specified directory.
const imageCompare = require("image-compared");
imageCompare.removeDuplicateImages("src/images", ["jpg", "jpeg", "png", "gif"]);