Versions in this module Expand all Collapse all v0 v0.27.1 Jul 30, 2020 Changes in this version + var ErrMetricsAddInInitContext = common.NewInitContextError("Adding to metrics in the init context is not supported") + type Metric struct + func (m Metric) Add(ctx context.Context, v goja.Value, addTags ...map[string]string) (bool, error) + type Metrics struct + func New() *Metrics + func (*Metrics) XCounter(ctx *context.Context, name string, isTime ...bool) (interface{}, error) + func (*Metrics) XGauge(ctx *context.Context, name string, isTime ...bool) (interface{}, error) + func (*Metrics) XRate(ctx *context.Context, name string, isTime ...bool) (interface{}, error) + func (*Metrics) XTrend(ctx *context.Context, name string, isTime ...bool) (interface{}, error)