Skip to content

Instantly share code, notes, and snippets.

@vaskaloidis
Last active December 23, 2019 21:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save vaskaloidis/ccf5fb62ab187033cd67a427cfdf542f to your computer and use it in GitHub Desktop.
Save vaskaloidis/ccf5fb62ab187033cd67a427cfdf542f to your computer and use it in GitHub Desktop.
<script>
window.onload = function() {
var target = document.getElementById('revealthis');
if( $('#yourtarget').is(':empty') ) {
target.style.display = 'block';
} else {
target.style.display = 'none';
}
};
</script>
<div id="yourtarget">
This is what your checking
</div>
<div id="revealthis" style="display:none">
</div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment