Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
A fuzzy search for domain urls using wikireverse
// GO TO https://wikireverse.org/
function inj(service){
service = service|| "$rootScope";
return angular.element(document.body).injector().get(service);
}
$http=inj('$http');
entries=[]
function getUrls(site, pages, start){
_.range(pages||100).map((page) => $http.get('https://api.wikireverse.org/site_search/'+site+'/sites?page='+((start||0)+page)).success( (r) => {entries=entries.concat(r);}))
}
limit=5
getUrls('wordpress.com',limit, 500)
// Check results
if(entries.length){
// Make sure they're unique
_.keyBy(entries, 'host')
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.