# Packages
Package prefs_example contains a [Prefs] type, which is like [tailscale.com/ipn.Prefs], but uses the [prefs] package to enhance individual preferences with state and metadata.
# Functions
ItemOf returns an [Item] configured with the specified value and [Options].
ItemViewOf returns a read-only view of i.
ItemWithOpts returns an unconfigured [Item] with the specified [Options].
ListOf returns a [List] configured with the specified value and [Options].
ListWithOpts returns an unconfigured [List] with the specified [Options].
MapOf returns a map configured with the specified value and [Options].
MapWithOpts returns an unconfigured [Map] with the specified [Options].
StructListOf returns a [StructList] configured with the specified value and [Options].
StructListViewOf returns a read-only view of l.
StructListWithOpts returns an unconfigured [StructList] with the specified [Options].
StructMapOf returns a [StructMap] configured with the specified value and [Options].
StructMapViewOf returns a readonly view of m.
StructMapWithOpts returns an unconfigured [StructMap] with the specified [Options].
# Variables
ErrManaged is the error returned when attempting to modify a managed preference.
ErrReadOnly is the error returned when attempting to modify a readonly preference.
Managed is an option that marks preference as managed.
ReadOnly is an option that marks preference as read-only.
# Structs
Item is a single preference item that can be configured.
ItemView is a read-only view of an [Item][T], where T is a mutable type implementing [views.ViewCloner].
List is a preference type that holds zero or more values of an [ImmutableType] T.
ListView is a read-only view of a [List].
Map is a preference type that holds immutable key-value pairs.
MapView is a read-only view of a [Map].
StructList is a preference type that holds zero or more potentially mutable struct values.
StructListView is a read-only view of a [StructList].
StructMap is a preference type that holds potentially mutable key-value pairs.
StructMapView is a read-only view of a [StructMap].
# Interfaces
BasicType is a constraint that allows types whose underlying type is a predeclared boolean, numeric, or string type.
ImmutableType is a constraint that allows [BasicType]s and certain well-known immutable types.
MapKeyType is a constraint allowing types that can be used as [Map] and [StructMap] keys.
# Type aliases
Options are used to configure additional parameters of a preference.