1const std = @import("std");
2const string = []const u8;
3const extras = @import("./lib.zig");
4
5pub fn base64EncodeAlloc(alloc: std.mem.Allocator, input: string) !string {
6 const base64 = std.base64.standard.Encoder;
7 const buf = try alloc.alloc(u8, base64.calcSize(input.len));
8 return base64.encode(buf, input);
9}
10
11test {
12 std.testing.refAllDecls(@This());
13}