remove empty fields on Elementor accordion

( function( $ ) {
$( window ).on( 'elementor/frontend/init', function() {
if ( $('.elementor-widget-n-accordion').length ) {
return;
}
constaccordionTitles=$('.e-n-accordion-item-title-text');
accordionTitles.each( function() {
if ( !$(this).text().trim().length ) {
$(this).parents('details').remove();
}
});
});

} )(jQuery);

Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.

Still need help? Contact Us Contact Us