imagebase64

package module
v0.0.0-...-a1f2994 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 28, 2026 License: MPL-2.0 Imports: 9 Imported by: 0

README

imagebase64

Package imagebase64 offers a few functions to base64 encode images so they can be used in transport protocols that are made for text.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Decode

func Decode(input string) (data []byte, contentType string, err error)

Decode decodes the base64 encoded data in input and returns the bytes and content type.

func Encode

func Encode(r io.Reader, contentType string) (string, error)

Encode encodes the image data in r to base64.

func EncodeFile

func EncodeFile(path string) (string, error)

EncodeFile encodes the image file at path to base64.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL