Search
 
SCRIPT & CODE EXAMPLE
 

TYPESCRIPT

calculate checksum typescript

var crypto = require('crypto')

function checksum(str, algorithm, encoding) {
  return crypto
    .createHash(algorithm || 'md5')
    .update(str, 'utf8')
    .digest(encoding || 'hex')
}

checksum('This is my test text') // e53815e8c095e270c6560be1bb76a65d
checksum('This is my test text', 'sha1') // cd5855be428295a3cc1793d6e80ce47562d23def
Comment

PREVIOUS NEXT
Code Example
Typescript :: how to access contents of an array from another class in java 
Typescript :: Lua programming - setting up physics 
Typescript :: Scroll,Position 
Typescript :: benefits of ginger juice 
Typescript :: graphql?query={__schema{types{name,fields{name}}}} 
Typescript :: set state array of objects react hooks 
Typescript :: Integer Which of the following can be described as the decision whether to obtain the necessary software from internal or external sources?and Development Environment meaning 
Typescript :: how to get all arrangments python 
Typescript :: accout 
Typescript :: how to append different lists in installed apps django 
Typescript :: redux toolkit socket io 
Typescript :: deleting a comnent from arrays of comments in mongodb 
Typescript :: get list of property values from list of objects swift 
Typescript :: typescript baseurl 
Typescript :: how to create nest without spec test filefile 
Typescript :: FIND TOP 3 students from math_11a table 
Typescript :: typescript import variable from another file 
Typescript :: typescript style guide 
Typescript :: install dependencies angular 
Typescript :: union type property does not exist 
Typescript :: You’re asked to read a file a line at a time. For each line, you have to split it into fields. Which of the following sets of pseudo class definitions is likely to be more orthogonal? 
Cpp :: how to make i/o fast in c++ 
Cpp :: c++ - include all libraries 
Cpp :: vector erase not working c++ 
Cpp :: how to output text in c++ 
Cpp :: c++ get length of array 
Cpp :: linked list with classes c++ 
Cpp :: c++ random between two values 
Cpp :: what are specialized classes c++ 
Cpp :: initialize a pair 
ADD CONTENT
Topic
Content
Source link
Name
8+6 =