View Source Luminous.Attributes (luminous v2.2.0)

Attributes map variable values (user-defined) to attribute keyword lists. They are created by parsing and validating a NimbleOptions schema (see parse/2).

Link to this section Summary

Functions

Parse the supplied keyword list using the specified schema (performs validations as well) Return a map

parse the supplied keyword list using the specified schema (performs validations as well) return a map or raise on error

Link to this section Types

Link to this section Functions

@spec parse(
  keyword(),
  Luminous.Attributes.Schema.t()
) :: {:ok, t()} | {:error, binary()}

Parse the supplied keyword list using the specified schema (performs validations as well) Return a map

@spec parse!(
  keyword(),
  Luminous.Attributes.Schema.t()
) :: map()

parse the supplied keyword list using the specified schema (performs validations as well) return a map or raise on error