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

Not working in my site #1

Open
Jookus opened this issue Apr 2, 2015 · 6 comments
Open

Not working in my site #1

Jookus opened this issue Apr 2, 2015 · 6 comments

Comments

@Jookus
Copy link

Jookus commented Apr 2, 2015

I always get this error:

Uncaught Error: adsbygoogle.push(): All ins elements in the DOM with class=adsbygoogle already have ads in them.

Is this element still compatible with the newest version of polymer?

@kessiler
Copy link
Owner

kessiler commented Apr 3, 2015

Thanks to report!
I will review and update the component.

@Jookus
Copy link
Author

Jookus commented Apr 4, 2015

I think the generated "ins"-node may not be found by the adsense library , because in my website it is created in the shadowDOM.

@Jookus Jookus closed this as completed Apr 4, 2015
@Jookus Jookus reopened this Apr 4, 2015
@a-haan
Copy link

a-haan commented Mar 14, 2017

Still not working after a few tests

@busynest
Copy link

create a slot within your custom element. then pass your adsense in throught your new tag. derf

@zricethezav
Copy link

Any update on this?

@busynest
Copy link

busynest commented Jul 13, 2017

Yes, I figured it out last night but have not got back to it yet.
This wrapper is not needed.
The problem is the custom element itself does not have functionality, because you have not written it in. derf, it's new!

I bet there is a js property you can set to communicate outside of the DOM wall, but I'll get there later.

For now, use the slot, because that is the standard now.

  1. add ">slot<" "> /slot<" into your custom element where you want to place your a.d.
  2. ">my-element<" Place AdSense Code Here ">/my-element<"
  • Your custom element should be loaded from app-shell (upper most container)

*This works because first slot is undefined and loads any content passed into the new tag.

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

No branches or pull requests

5 participants