I am trying to do base64 encode in NodeJS using TypeScript.
Following code working fine in JavaScript.
When I am writing same thing in TypeScript and compiling, I am getting Buffer is not find error.
var base64Policy = new Buffer(stringPolicy, 'utf-8').toString('base64');
Can someone help me to do same thing in TypeScript.
See Question&Answers more detail:os