
Research
/Security News
Contagious Interview Campaign Escalates With 67 Malicious npm Packages and New Malware Loader
North Korean threat actors deploy 67 malicious npm packages using the newly discovered XORIndex malware loader.
text-mask-all
Advanced tools
Conforms string to given mask or pattern, and can be hooked up to input element
Text Mask let's you turn a plain <input />
, into one that conforms
any user input, as they type, to a given mask pattern.
To see Text Mask in action, checkout the demo page.
IE9+, Android, Samsung Internet, Windows Phone, iOS, Opera, Firefox, Safari, and Chrome
Character | Description |
---|---|
1 | Any number |
A | Any letter |
? | Any number or letter |
U | Any letter (will be transformed to uppercase) |
L | Any letter (will be transformed to lowercase) |
The mask also supports escaping, so you can use a masking character within the mask. For example
+\1 (111) 111-1111
The first 1
is not a masking character but part of the mask. For more information, see the
documentation here.
Guide mode prints out placeholder characters and the mask itself as the user types
No-guide mode doesn't print out placeholder characters and only adds mask characters when the user reaches them
You can change the placeholder character from _
(underscore) to anything you want. For example,
you can use the unicode character U+2000
(\u2000
in JavaScript), which is white space to
create a mask for phone number that looks like
+1 ( ) -
Or for date
/ /
Please file an issue or tweet at me.
Public domain - CC0 1.0 Universal
FAQs
Conforms string to given mask or pattern, and can be hooked up to input element
We found that text-mask-all demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
/Security News
North Korean threat actors deploy 67 malicious npm packages using the newly discovered XORIndex malware loader.
Security News
Meet Socket at Black Hat & DEF CON 2025 for 1:1s, insider security talks at Allegiant Stadium, and a private dinner with top minds in software supply chain security.
Security News
CAI is a new open source AI framework that automates penetration testing tasks like scanning and exploitation up to 3,600× faster than humans.