fix: avoid having multiple ads

pull/370/head
Eduardo San Martin Morote 4 years ago
parent c3ce55dfb4
commit b835816296

@ -45,6 +45,10 @@ onMounted(() => {
function load() { function load() {
if (typeof _bsa !== 'undefined' && _bsa) { if (typeof _bsa !== 'undefined' && _bsa) {
const parent = document.querySelector('.bsa-cpc')!
// cleanup any existing ad to avoid them stacking
parent.innerHTML = ''
_bsa.init('default', code, `placement:${placement}`, { _bsa.init('default', code, `placement:${placement}`, {
target: '.bsa-cpc', target: '.bsa-cpc',
align: 'horizontal', align: 'horizontal',

Loading…
Cancel
Save