Workaround für random <p> Tag Generierung bei gemixtem Content in Shortcodes vorläufig implementiert
This commit is contained in:
parent
9d94808d94
commit
0621d47b86
1 changed files with 10 additions and 0 deletions
10
assets/js/custom.js
Normal file
10
assets/js/custom.js
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
function removeEmptyParagraphs() {
|
||||
const paragraphs = document.querySelectorAll('p');
|
||||
paragraphs.forEach(paragraph => {
|
||||
if (!paragraph.textContent.trim() && !paragraph.querySelector('i')) {
|
||||
paragraph.remove();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
removeEmptyParagraphs();
|
||||
Loading…
Add table
Add a link
Reference in a new issue