am trying to manage the cookies set by facebook (_fbp, fr, xs, sb). The SDK is needed to enable FB login.
The project React based but most of the stuff is handled with JS.
At the same time it be great if the user could opt-out from having those cookies set.
the code used is outdated v3.3
window.FB.init({
appId: Settings.settings.facebookAppID,
cookie: true,
xfbml: true,
version: 'v3.3'
});
window.FB.AppEvents.logPageView();
};
(function(d, s, id) {
var js,
fjs = d.getElementsByTagName(s)[0];
if (d.getElementById(id)) {
return;
}
js = d.createElement(s);
js.id = id;
js.src = '//connect.facebook.net/en_US/sdk.js';
fjs.parentNode.insertBefore(js, fjs);
})(document, 'script', 'facebook-jssdk');
What would be the best way to approach this ?