Skip to content

Commit ec3b6f7

Browse files
authored
Merge pull request #546 from bitdefender/fix-laning-page
dynamically import decorateButtons for landing page bugfix
2 parents 8d5f0da + 580a273 commit ec3b6f7

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

_src/blocks/hero-aem/hero-aem.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
/* eslint-disable prefer-const */
22
/* eslint-disable no-undef */
33
/* eslint-disable max-len */
4-
import { decorateButtons } from '../../scripts/lib-franklin.js';
54
import {
65
openUrlForOs, createNanoBlock, renderNanoBlocks, createTag,
76
} from '../../scripts/utils/utils.js';
@@ -255,6 +254,10 @@ export default async function decorate(block, options) {
255254
listTable.classList.add('ratings');
256255
// delete the first row
257256
listTable.deleteRow(0);
257+
258+
// Dynamically import the decorateButtons function, bugfix for landing page
259+
// eslint-disable-next-line no-await-in-loop
260+
const { decorateButtons } = await import('../../scripts/lib-franklin.js');
258261
decorateButtons(listTable);
259262
// listTable.querySelector('a').classList.add('button');
260263
}

0 commit comments

Comments
 (0)