how can i get a response function after tweeted successfullly ?!
twttr.widgets.createShareButton(
'/',
document.getElementById('new-button'),
{
count: 'none',
text: url
}).then(function (el) {
console.log("Button created.");
});
//event bind
**twttr.events.bind('tweet', handleTweetEvent);**
function handleTweetEvent(event) {
SomeCode();
}
but i just want to trigger the function ‘SomeCode()’ when it tweeted successfully ;