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

Prebid 8 - Convert Mass module to generic deal rendering module #9888

Closed
Tracked by #9362
patmmccann opened this issue May 1, 2023 · 2 comments
Closed
Tracked by #9362

Prebid 8 - Convert Mass module to generic deal rendering module #9888

patmmccann opened this issue May 1, 2023 · 2 comments

Comments

@patmmccann
Copy link
Collaborator

patmmccann commented May 1, 2023

https://github.com/prebid/Prebid.js/blob/master/modules/mass.js has lost its maintaining company but still has useful functionality; applying a renderer when the deal code meets a regex pattern. We want to strip all the branding and require the regex to be configurable instead of having a default

@patmmccann patmmccann changed the title Mass (module) - massplatform.net @cciocov Prebid 8 - Convert Mass module to generic deal rendering module May 1, 2023
@dgirardi
Copy link
Collaborator

dgirardi commented May 3, 2023

This can work as an alternative:

pbjs.onEvent('bidResponse', (bid) => {
    if (bid.dealId /* or any other condition */) {
        bid.renderer = {
            renderNow: true,
            render(bid, doc) {
                // do your own rendering
                doc.body.innerHTML = bid.ad;
            }
        }
    }
})

@patmmccann
Copy link
Collaborator Author

opened as prebid/prebid.github.io#4535

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Development

No branches or pull requests

2 participants