Hello, this is most likely a fairly simple question, but I have a javascript snippet that I want to run on all tiddlers tagged with “Outline”. The snippet is below. How would I do this?
const list = document.querySelector('.collapsible-list');
list.addEventListener('click', (event) => {
const listItem = event.target.closest('li');
if (listItem) {
const childList = listItem.querySelector('ul');
if (childList) {
listItem.classList.toggle('open');
}
}
});