Last active
May 19, 2021 01:35
-
-
Save m3l1nd4/d32a9a18c66482121017d56f82700884 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
return { | |
on: { | |
pageInit: function (e, page) { | |
const newCommentBtn = document.querySelector('#new-comment'); | |
// Toggle UI Element | |
auth.onAuthStateChanged(user => { | |
(user) | |
? newCommentBtn.classList.remove('display') | |
: newCommentBtn.classList.add('display'); | |
}); | |
} | |
} | |
} | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment