Closed wcjohnson11 closed 8 years ago
These same IE9 errors are failing on Master as well. Circle Master Test Circle Branch Test
corresponding to the following blocks https://github.com/segment-integrations/analytics.js-integration-facebook-pixel/blob/master/test/index.test.js#L69 https://github.com/segment-integrations/analytics.js-integration-facebook-pixel/blob/master/test/index.test.js#L80-L82
This line is where the error is occuring. https://github.com/segment-integrations/analytics.js-integration-facebook-pixel/blob/master/lib/index.js#L43
This is being caused in IE9 by a change in the process
shim browserify puts in. @tsholmes is working on a fix that will get these tests to pass.
@ndhoule @hankim813 @tsholmes
Could you guys take a look at this PR?
This PR adds support for Facebook Advanced Pixel Matching. https://developers.facebook.com/docs/facebook-pixel/pixel-with-ads/conversion-tracking#advanced_match
On initialize, we check for a user's traits that have been cached by A.js and fill in any matching attributes that are recognized by Facebook.
I removed the explicit overwriting of window.fbq on every page load so that it would be easier to test and because their snippet returns the existing
fbq
on initialization if window.fbq is already defined. I tested this and saw the pixels firing.