Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inject creativeComment after render so it actually persists #6860

Merged
merged 2 commits into from
Jul 7, 2021

Conversation

jsut
Copy link
Contributor

@jsut jsut commented May 27, 2021

Type of change

  • Bugfix

Description of change

pbjs.renderAd currently injects an HTML comment into the body tag of the document passed in. This comment seems to get eaten up in any case where an ad is actually rendered successfully. Some bid adapters insert a comment similar to this in their renderers, but some don't. This change moves the actual injection of the comment to the HTML tag of the document, as well as changing it to run after the ad has been rendered. In my testing this actually results in a comment that you can see in the DOM for the adapters I happened to get demand from during manual testing.

I suppose there could/should be some tests for this, but i haven't written any since there aren't any renderAd tests that care about this comment. I'd be happy to look into getting some working if desired.

@smenzer smenzer added bugfix needs 2nd review Core module updates require two approvals from the core team needs review labels May 28, 2021
@jsnellbaker jsnellbaker self-requested a review June 1, 2021 13:23
Copy link
Contributor

@mmoschovas mmoschovas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@mmoschovas
Copy link
Contributor

@jsut can these conflicts be resolved so this can be merged?

@jsut
Copy link
Contributor Author

jsut commented Jul 6, 2021

@mmoschovas rebased on master

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugfix minor needs 2nd review Core module updates require two approvals from the core team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants