Effect CommunityEC
Effect Community2y ago
26 replies
nemmind1

Schema base64 string -> utf8 string -> json parse

It is possible to do this with only built-in schema functions?
I found the Base64 function which results an Uint8Array but I cannot find any functions to convert it to an utf8 string. After that I could use the parseJson function.

In plain js it looks like this:

JSON.parse(Buffer.from(base64String, 'base64').toString('utf-8'))


Thanks!
Was this page helpful?