Created
December 17, 2019 19:36
-
-
Save tripflex/d6b995a4141b3e56f6b530cf08ca4aac to your computer and use it in GitHub Desktop.
Hide/Obfuscate/Mask Email Address from Spam Bots (Vue.js Component)
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
<template> | |
<span class="reverse">{{reversedEmail}}</span> | |
</template> | |
<script> | |
export default { | |
name: 'hide-email', | |
props: [ 'email' ], | |
computed: { | |
reversedEmail(){ | |
return this.email.split("").reverse().join("") | |
} | |
} | |
} | |
</script> | |
<style scoped> | |
span.reverse { | |
unicode-bidi: bidi-override; | |
direction: rtl; | |
} | |
</style> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
but it doesn't work with cmd c (mac) or control C (windows)
Most of the user just copy e-mail like that, and never click it, to open the default e-mail app in computer.
Most of users prefer to use gmail or hotmail site instead