Prebid.js icon indicating copy to clipboard operation
Prebid.js copied to clipboard

0.11.0 Not loading analytics sources

Open jalbersmead opened this issue 10 years ago • 8 comments

It seems the analyticsDirectory value in gupfile.js is pointing to the wrong location. Instead of ../analytics it should be ./src/adapters/analytics or at least that's what I had to do to get it to build correctly.

jalbersmead avatar Jul 25 '16 20:07 jalbersmead

Thanks for contacting us @jalbersmead We will look into this and get back to you as soon as possible.

jaiminpanchal27 avatar Jul 26 '16 01:07 jaiminpanchal27

@jalbersmead What's your build look like? Are you adding a custom adapter into ./src/adapters/analytics ? AFAIK that should work ok. If you have fork can you link it?

mkendall07 avatar Jul 26 '16 13:07 mkendall07

I didn't fork it since it was just a change to the gulpfile.js. I also realized that the documentation for enabling the GA analytics was missing an important step: In package.json, you have to specifically enable an analytics adapter. I filed an issue with the prebid.github.io project for that one.

jalbersmead avatar Jul 26 '16 16:07 jalbersmead

@jalbersmead So just so I understand correctly, you are just trying to load GA adapter for analytics correct?

mkendall07 avatar Jul 27 '16 20:07 mkendall07

Correct. Nothing custom, just the default one included in the 0.11.0 source

jalbersmead avatar Jul 27 '16 22:07 jalbersmead

GA analytics should work if you add 'ga' to the analytics array in package.json.

protonate avatar Aug 09 '16 22:08 protonate

analyticsDirectory in gulpfile.js is used to bundle an analytics library from an adjacent directory with Prebid, so it's pointing at the correct location. Since ga is within the Prebid src directory you should be abel to add it to analytics in package.json as @protonate mentioned and run gulp build to build with ga analytics.

matthewlane avatar Aug 09 '16 22:08 matthewlane

Closing this as you should be able to use the method specified by @protonate to resolve.

mkendall07 avatar Aug 11 '16 14:08 mkendall07