import { IsoBuffer } from "./indexNode" ; export const fromBase64ToUtf8 = ( input ) : string => IsoBuffer . from ( input , "base64" ) . toString ( "utf-8" ) ; export const fromUtf8ToBase64 = ( input ) : string => IsoBuffer . from ( input , "utf8" ) . toString ( "base64" ) ; param input param encoding export const toUtf8 = ( input , encoding ) : string => { switch ( encoding ) { case "utf8" : case "utf-8" : return input ; default : return IsoBuffer . from ( input , encoding ) . toString ( ) ; } } ;