Skip to content

Instantly share code, notes, and snippets.

@jamesongithub
Created November 29, 2018 22:36
Show Gist options
  • Save jamesongithub/89a4fd535ae6126f0de5175707b72003 to your computer and use it in GitHub Desktop.
Save jamesongithub/89a4fd535ae6126f0de5175707b72003 to your computer and use it in GitHub Desktop.
expand splunk json
javascript:function autoExpand() { var found = false; $(document).ready(function() { $(".jsexpands").each(function() { if ($(this).html() == '[+]') { found = true; $(this)[0].click(); } }); }); if (found) { setTimeout(function() { $('.modalize-table-overlay').click(); }, 500); } } var target = document.body; var observer = new MutationObserver(function(mutations) { autoExpand(); }); var config = { attributes: true, childList: true, characterData: true, subtree: true }; observer.observe(target, config);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment