binfs

package
v0.0.0-...-7078e10 Latest Latest
Warning

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

Go to latest
Published: Dec 14, 2021 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Mode bingen.Mode
	Gzip bool
	Data interface{}
}

func (Config) MustPreload

func (c Config) MustPreload() FileSystem

func (Config) New

func (c Config) New() FileSystem

func (Config) Preload

func (c Config) Preload() (FileSystem, error)

type FileSystem

type FileSystem interface {
	http.FileSystem
	Preload() (FileSystem, error)
	ReadFile(path string) ([]byte, error)
}

func Override

func Override(path string, fs FileSystem) (FileSystem, error)

Override a FileSystem with a physical path - use this in development to mask the baked-in FileSystem with updatable versions stored locally.

Jump to

Keyboard shortcuts

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