Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save LarrySul/9aa0e435274886317dc368990417faee to your computer and use it in GitHub Desktop.
Save LarrySul/9aa0e435274886317dc368990417faee to your computer and use it in GitHub Desktop.
$('btn').click(() => {
$(this).toggleClass('highlight')
$(this).text() === 'Add Highlight'
? $(this).text('Remove Highlight')
: $(this).text('Add Highlight')
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment