export type DigestAlgorithm = typeof digestAlgorithms[number];
export type DigestAlgorithm = typeof digestAlgorithms[number];
(I don't quite see what is going on here and am interested.)
Bottom line is, when I make algo:string a algo:DigestAlgorithm in the digest function param list, it stops complaining, but I need to have some calling code somewhere be a flexible string (or maybe an enum if necessary) that somehow translates to a DigestAlgorithm for this to work.