Fix for non-lazy-load ads not displaying correctly #97
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Changes
sizeMapping
andsetTargeting
on the globalwindow.dfw
to match the parameters required by https://github.com/coop182/jquery.dfp.js#available-optionsjquery.dfw.js
, so that the code will hopefully only be loaded whenjquery.dfp.min.js
has been loaded, sincejquery.dfw.js
is listed as havingjquery.dfp.min.js
orjquery.dfp.js
as a dependency.jquery.dfp.js
from the repo, for Review all places where jquery.dfp.js and jquery.dfp.min.js are referenced #94Why
jquery.dfp.js
to be loaded after the plugin function that used functionality defined injquery.dfp.js
.jquery.dfp
is listed as a dependency ofjquery.dfw
in the enqueues, and Autoptimize was allowing lazy-load ads to load, so it seems that Autoptimize was loading ads in correct order. This changeset doesn't fix a potential future issue wherejquery.dfp.js
finishes loading beforejquery.dfw
does, but that seems unlikely ifjquery.dfw
is loaded later on the page thanjquery.dfp
, because they're loaded from the same origin.For #95 and #96.
Resolves #94
Testing/Questions
Questions that need to be answered before merging:
readme.txt
with appropriate information?Steps to test this PR: