Essentially, my import statement looks like this:
import { Md5 } from 'ts-md5/dist/md5';
However, the error message indicates that:
Module has no exported member Md5?
Although it seems to work fine, I am encountering an error during compilation.
To address this, I modified it to use lowercase md5
like so:
import { md5 } from 'ts-md5/dist/md5';
But now, my function is not functioning properly:
hashIt(email: string){
this.hashString = md5.hashStr(email);
console.log(this.hashString);
}
This results in the following error:
Property 'hashStr' does not exist on type '(string : any) => string'.