1.1.1 • Published 4 years ago
doesnotexist v1.1.1
DoesNotExist
Fetches random image from thispersondoesnotexist.com
Example
const doesnotexists = require("doesnotexist");
const fs = require("fs");
// person
doesnotexists("person")
.then(x => fs.writeFileSync("./person.png", x))
.catch(console.error);
// horse
doesnotexists("horse")
.then(x => fs.writeFileSync("./horse.png", x))
.catch(console.error);
// cat
doesnotexists("cat")
.then(x => fs.writeFileSync("./cat.png", x))
.catch(console.error);
// art
doesnotexists("artwork")
.then(x => fs.writeFileSync("./art.png", x))
.catch(console.error);