Sha256: b9daa7262714e54c276a6eff7fae75f0c8e01ca10a9786f189c0d9f00760e45e
Contents?: true
Size: 399 Bytes
Versions: 12
Compression:
Stored size: 399 Bytes
Contents
const slideHeadingList = document.querySelectorAll('.hero-slider__slider--slide-heading'); // Element from HTML const regEx = /\*\*([^\*]+)\*\*/g; const replacement = '<span class="typography__power-text">$1</span>'; function wrapPowerText() { [...slideHeadingList].forEach(heading => { heading.innerHTML = heading.innerHTML.replace(regEx, replacement); }) } export default wrapPowerText;
Version data entries
12 entries across 12 versions & 1 rubygems