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

feat: Allow overriding prebid mediaTypes #40

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

Fumler
Copy link

@Fumler Fumler commented Jun 22, 2019

On this branch

We might not always want to have the same sizes config set in GPT and prebid. This change uses the old method by default, but allows you to override the mediaTypes object in the prebid config.

E.g:

arcAds.registerAd({
        id: 'div-id-123',
        slotName: 'hp/hp-1',
        adType: 'cube',
        dimensions: [[300, 250], [300, 600]],
        display: 'all',
        targeting: {
          section: 'weather'
        },
        bidding: {
          prebid: {
            enabled: true,
            mediaTypes: {
              banner: {
                sizes: [980, 300]
              }
            },
            bids: [{
              bidder: 'appnexus',
              labels: ['desktop', 'tablet', 'phone'],
              params: {
                placementId: '10433394'
              }
            }]
          }
        }
      });

Verify

  • Confirm that cross browser testing has been completed.

  • Verify that no errors are present in the GPT console window.googletag.openConsole().

Comments

Love using ArcAds so far, great work!

Jest is complaining about "SecurityError: localStorage is not available for opaque origins", setting testURL to localhost removes this error
You might not always want to use the same sizes in GPT and prebid, this change enables overriding mediaTypes.
@design1online design1online added the under consideration testing this functionality to potentially merge it label Jan 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
under consideration testing this functionality to potentially merge it
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants