$(document).ready(function() {
posts_html = '';
if($("#pluginInsta").length) {
function nFormatter(num){
if(num >= 1000000000){
return (num/1000000000).toFixed(1).replace(/\.0$/,'') + 'G';
}
if(num >= 1000000){
return (num/1000000).toFixed(1).replace(/\.0$/,'') + 'M';
}
if(num >= 1000){
return (num/1000).toFixed(1).replace(/\.0$/,'') + 'K';
}
return num;
}
$.ajax({
url:"https://www.instagram.com/reedesbrasil?__a=1",
type:'get',
success:function(response){
posts = response.graphql.user.edge_owner_to_timeline_media.edges;
allItens = "";
for(var i=0;i';
allItens += '
';
}
$("#pluginInsta").append(allItens);
}
})
}
})