LucasLeandro1204 / Pornsearch

Easy way to search for porn content!
MIT License
329 stars 68 forks source link

how to only get 1 url? #33

Closed babycreeper189 closed 4 years ago

babycreeper189 commented 4 years ago

Is this possable?

babycreeper189 commented 4 years ago

Nevermind

babycreeper189 commented 4 years ago

answer:

const pornsearch = require("pornsearch"); const search = new pornsearch("sex");

search.gifs(1) .then(gifs => { const gifurls = gifs.map(gif => gif.url); const gifsStrings = JSON.stringify(gifurls); const gifsite = JSON.parse(gifsStrings); const url = gifsite[1];

    console.log(url)

});