html2image

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Jun 20, 2023 License: CC0-1.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	NO_IMAGE_SOURCE      = "sem imagem de origem"
	NO_IMAGE_DESTINATION = "sem imagem de destino"
)

Variables

This section is empty.

Functions

func AssetToBase64

func AssetToBase64(path string) string

func GetMimeType

func GetMimeType(path string) string

Types

type HTML2Image

type HTML2Image struct {
	// contains filtered or unexported fields
}

func New

func New() *HTML2Image

func (*HTML2Image) GenerateImage

func (h *HTML2Image) GenerateImage() error

func (*HTML2Image) GetDestination

func (h *HTML2Image) GetDestination() string

func (*HTML2Image) LoadDynamicTemplate

func (h *HTML2Image) LoadDynamicTemplate(templatePath string, assets, data map[string]string) error

func (*HTML2Image) SetDestination

func (h *HTML2Image) SetDestination(destinationFile string)

func (*HTML2Image) SetImageDirectory added in v0.0.4

func (h *HTML2Image) SetImageDirectory(imageDirectory string)

func (*HTML2Image) SetScreenWidth

func (h *HTML2Image) SetScreenWidth(screenWidth uint64)

func (*HTML2Image) SetSource

func (h *HTML2Image) SetSource(source string)

func (*HTML2Image) SetUseExec

func (i *HTML2Image) SetUseExec(useExec bool)

Jump to

Keyboard shortcuts

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