cfruntimecontext

package
v0.26.0 Latest Latest
Warning

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

Go to latest
Published: Apr 27, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrValueNotFound = errors.New("execution context value for specified key not found")

Functions

func GetRuntimeContextValue added in v0.21.0

func GetRuntimeContextValue(key string) (js.Value, error)

GetRuntimeContextValue gets value for specified key from RuntimeContext. - if the value is undefined, return error.

func MustGetRuntimeContextEnv added in v0.21.0

func MustGetRuntimeContextEnv() js.Value

MustGetRuntimeContextEnv gets object which holds environment variables bound to Cloudflare worker. - see: https://github.com/cloudflare/workers-types/blob/c8d9533caa4415c2156d2cf1daca75289d01ae70/index.d.ts#L566

func MustGetRuntimeContextValue added in v0.21.0

func MustGetRuntimeContextValue(key string) js.Value

MustGetRuntimeContextValue gets value for specified key from RuntimeContext. - if the value is undefined, this function panics.

Types

This section is empty.

Jump to

Keyboard shortcuts

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