Credo v1.2.0-rc3 Credo.Check.Params View Source

This module provides functions for handling parameters (“params”) given to checks through .credo.exs (i.e. the Credo.ConfigFile).

Link to this section Summary

Functions

Returns the given field’s params value

Link to this section Functions

Link to this function get(params, field, default_params \\ []) View Source

Returns the given field’s params value.

Example:

iex> Credo.Check.Params.get([], :foo, [foo: "bar"])
"bar"
iex> Credo.Check.Params.get([foo: "baz"], :foo, [foo: "bar"])
"baz"