Documentation
¶
Overview ¶
Package requestlog logs every request a Tern app serves, with slog:
ternApp(kit.WithPlugins(requestlog.New()))
Each line has the method, path, status, duration and response size. 5xx responses log at error level and 4xx at warn; everything else at info.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Option ¶
type Option func(*Plugin)
Option configures the plugin.
func SkipAssets ¶
func SkipAssets() Option
SkipAssets leaves out requests for /_app/ assets and other files with an extension, which are usually noise.
Click to show internal directories.
Click to hide internal directories.