Skip to content

Commit e04668f

Browse files
committed
commentred out buildHeroBlock for now
1 parent f6d0515 commit e04668f

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

scripts/scripts.js

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -17,16 +17,16 @@ import {
1717
* Builds hero block and prepends to main in a new section.
1818
* @param {Element} main The container element
1919
*/
20-
function buildHeroBlock(main) {
21-
const h1 = main.querySelector('h1');
22-
const picture = main.querySelector('picture');
23-
// eslint-disable-next-line no-bitwise
24-
if (h1 && picture && (h1.compareDocumentPosition(picture) & Node.DOCUMENT_POSITION_PRECEDING)) {
25-
const section = document.createElement('div');
26-
section.append(buildBlock('hero', { elems: [picture, h1] }));
27-
main.prepend(section);
28-
}
29-
}
20+
// Commenting out the unused function to avoid lint/build failures
21+
// function buildHeroBlock(main) {
22+
// const h1 = main.querySelector('h1');
23+
// const picture = main.querySelector('picture');
24+
// if (h1 && picture && (h1.compareDocumentPosition(picture) & Node.DOCUMENT_POSITION_PRECEDING)) {
25+
// const section = document.createElement('div');
26+
// section.append(buildBlock('hero', { elems: [picture, h1] }));
27+
// main.prepend(section);
28+
// }
29+
// }
3030

3131
/**
3232
* load fonts.css and set a session storage flag

0 commit comments

Comments
 (0)