prebid / Prebid.js

Setup and manage header bidding advertising partners without writing code or confusing line items. Prebid.js is open source and free.
https://docs.prebid.org
Apache License 2.0
1.28k stars 2.05k forks source link

Feature request: native rendering without specifying a url of the renderer #6695

Closed bjorn-lw closed 1 year ago

bjorn-lw commented 3 years ago

Type of issue

Question about native rendering

Description

Several of our customers who run native ads don't use GAM/AppNexus or sometimes not even an ad server at all.

This makes the proposed rendering techniques (https://docs.prebid.org/prebid/native-implementation.html) unnecessary complicated since they often already have existing functionality for rendering native ads via JavaScript from before header bidding when they had direct integrations with Native ad providers.

To simplify setup, we use the existing render functionality in Prebid.js by setting

mediatypes.native.renderer = { url: 'someurl', render: ...renderfunction on customer's site }

which works really well with only minor modifications to the customer's already existing rendering code.

We used to set url to only '//' since the rendering code was already present on site and no external script needed to be loaded, but this seem to have stopped working with https://github.com/prebid/Prebid.js/pull/6422. Now we simply point to a minimal CDN-hosted js file, which works even though it's not really optimal.

So the question(s):

  1. Is this way of rendering native ads something that will continue to be supported by Prebid or are we abusing the renderer functionality and it may break at any time? My main concern is that everywhere, even though this practically works for native, it's only mentioned together with "outstream". In Renderer.js, it explicitly tests for 'mediatypes.video.renderer', but not 'mediatypes.native.renderer'. The Renderer.js moduleCode is also set to "outstream".
  2. If this functionality is OK to continue using, would it be acceptable to make it possible to omit the url parameter if the rendering code is already present/loaded on site?
  3. And finally, if it will continue to be supported it would be nice to also document it.

I could certainly volunteer to do some/all changes required (if any) above, but if it's against prebid's design principles I guess it's not a good idea to start working on it.

naegelin commented 3 years ago

I would generally agree with you and argue that the custom renderer should be consistently implemented and supported on all mediatypes . I also think it would make sense that if renderer.render provides a function without a renderer.url then prebid should assume that the function is available to prebid from the page.

vlouppe commented 3 years ago

Same issue for us. We are using the renderer for native ads without url.

ChrisHuie commented 3 years ago

@bjorn-lw we have been talking about splitting off a sub-committee for native to get more expertise focused on issues like this. Sounds like this would be a +1 for that on learning more how native is actually being used in the wild.

ChrisHuie commented 3 years ago

@guiann you know more about prebid native rendering than I do. Is this a problem you come across also?

naegelin commented 3 years ago

Magnite is currently reviewing the native rendering implementation as well as other native implementation challenges of pbjs and will be submitting a comprehensive proposal for the community to review in the coming weeks. Once submitted this would probably be an opportune time to form a sub-committee if others deem it to be necessary / meaningful .

stale[bot] commented 2 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

patmmccann commented 2 years ago

@naegelin curious for an update?

naegelin commented 2 years ago

Hey @patmmccann I am no longer with Magnite - I would check with @caitlinwright123

jlustig11 commented 2 years ago

The src/Renderer.js file is for outstream videos. I do not think this should be permitted. I propose a check that allows this "renderer" only for videos here.

I do think however enabling native to check for a render function is fine, but only when the mediaType is native.

samuel-palmer-relevant-digital commented 1 year ago

The src/Renderer.js file is for outstream videos. I do not think this should be permitted. I propose a check that allows this "renderer" only for videos here.

I should mention that we're also using mediaTypes.native.renderer as it simplifies integration on sites a lot and works well with existing prebid line items without having to use special native creatives.

So while it might make sense to add another method to implement the same behavior, I for sure hope that support of mediaTypes.native.renderer isn't "suddenly" dropped.

(apologize if I misunderstood the suggestion)

patmmccann commented 1 year ago

looks to be solved by https://github.com/prebid/Prebid.js/pull/9769