mirror of
https://github.com/CorentinTh/it-tools.git
synced 2025-04-25 17:26:15 -04:00
feat(hash-text): digest base selector (#254)
This commit is contained in:
parent
fad4833ca2
commit
422b6eb05a
3 changed files with 62 additions and 7 deletions
7
src/tools/hash-text/hash-text.service.ts
Normal file
7
src/tools/hash-text/hash-text.service.ts
Normal file
|
@ -0,0 +1,7 @@
|
|||
export function convertHexToBin(hex: string) {
|
||||
return hex
|
||||
.trim()
|
||||
.split('')
|
||||
.map((byte) => parseInt(byte, 16).toString(2).padStart(4, '0'))
|
||||
.join('');
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue