You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Even though your code seems like it should be passing through any script not explicitly blocked in its settings, the app is effectively blocking other scripts that are being created dynamically. I have tried debugging this myself but to no avail. In particular there seems to be an issue in the modifyCreateElement function that is causing normal document.createElement('script') tags to not have their src attribute loaded properly. Have you encountered this before?
When I disable the app optimization my Facebook Pixel sales channel script executes properly again. I would like to be able to use both, please advise.
To reproduce, create a store with the Facebook & Instagram sales channel connected with a Facebook pixel and any other plugin to be optimized. Add the app optimization code and configure it to block the other plugin on the homepage. Using the Facebook Pixel Debugger observe how the pixel code is working on every page but the homepage.
The text was updated successfully, but these errors were encountered:
Tanisyr
changed the title
Facebook Pixel script not loading
Facebook Pixel script and others not loading
May 22, 2024
I found my issue. For some reason some of the Shopify code was passing a src attribute that was not a string, but an instance of TrustedScriptURL, which doesn't contain an indexOf method. This was causing your url comparison logic to error out and prevent the src attribute from being set correctly on certain script.
Even though your code seems like it should be passing through any script not explicitly blocked in its settings, the app is effectively blocking other scripts that are being created dynamically. I have tried debugging this myself but to no avail. In particular there seems to be an issue in the modifyCreateElement function that is causing normal document.createElement('script') tags to not have their src attribute loaded properly. Have you encountered this before?
When I disable the app optimization my Facebook Pixel sales channel script executes properly again. I would like to be able to use both, please advise.
To reproduce, create a store with the Facebook & Instagram sales channel connected with a Facebook pixel and any other plugin to be optimized. Add the app optimization code and configure it to block the other plugin on the homepage. Using the Facebook Pixel Debugger observe how the pixel code is working on every page but the homepage.
The text was updated successfully, but these errors were encountered: