Harper.Lint (harper v0.1.1)

Copy Markdown View Source

A single problem Harper found in a piece of text.

Fields:

  • :start, :end — UTF-16 code-unit offsets into the linted string, end-exclusive. See Harper for why UTF-16.
  • :message — human-readable description of the problem.
  • :kind — category string from harper-core's LintKind (e.g. "Spelling", "Agreement", "WordChoice"); useful for grouping or styling in a UI.
  • :priority — importance, lower is more important.
  • :suggestions — zero or more Harper.Suggestion edits that resolve it.

Summary

Types

t()

@type t() :: %Harper.Lint{
  end: non_neg_integer(),
  kind: String.t(),
  message: String.t(),
  priority: non_neg_integer(),
  start: non_neg_integer(),
  suggestions: [Harper.Suggestion.t()]
}