Alternera.Plugin.Editor.StatusSuggestions (alternera_plugin_editor v0.9.0)

Copy Markdown View Source

HTTP statuses as a comma-separated status field's <.suggest_input mode="list"> offers them, each with its reason phrase under it.

codes/0 is the common statuses, in number order, for a field that takes numbers only (a response cache's Statuses). with_classes/0 puts the five classes (2xx …) first, for a field that also takes a class or a range (a Request step's Success statuses).

Summary

Types

An entry as the SuggestInput hook reads it.

Functions

The common statuses, each with its reason phrase.

The five status classes, then codes/0.

Types

suggestion()

@type suggestion() :: %{value: String.t(), description: String.t()}

An entry as the SuggestInput hook reads it.

Functions

codes()

@spec codes() :: [suggestion()]

The common statuses, each with its reason phrase.

with_classes()

@spec with_classes() :: [suggestion()]

The five status classes, then codes/0.