Manages the icon manifest stored in priv/.
The manifest contains all discovered icons, cached between compilations.
Summary
Functions
Adds an icon to the runtime cache and optionally persists to disk.
Clears the cached icons.
Returns the number of icons in the manifest.
Gets icons from the manifest, loading from persistent storage on first use.
Returns the path to the manifest file for the given application.
Reads the manifest from disk.
Reloads icons from disk into persistent_term.
Writes the manifest to disk.
Functions
Adds an icon to the runtime cache and optionally persists to disk.
Clears the cached icons.
Returns the number of icons in the manifest.
Gets icons from the manifest, loading from persistent storage on first use.
Returns the path to the manifest file for the given application.
@spec read(Path.t() | nil) :: %{required(String.t()) => Iconify.Icon.t()}
Reads the manifest from disk.
Missing manifests are treated as empty. Invalid manifests raise.
Reloads icons from disk into persistent_term.
@spec write(%{required(String.t()) => Iconify.Icon.t()}, Path.t() | nil) :: :ok
Writes the manifest to disk.