WithFormatter (pretty_arrows v0.3.0)

Copy Markdown View Source

A mix format plugin that aligns only the arrows in with clauses.

Use it instead of PrettyArrows if you don't want Ecto field alignment:

[
  plugins: [WithFormatter],
  pretty_arrows: [with: [enabled: true, padding: :right]]
]

Only the :with section of :pretty_arrows is read. See PrettyArrows for the options.

Summary

Functions

Returns the Mix.Tasks.Format features for this plugin. mix format calls this function, so you don't need to call it yourself.

Formats source and aligns its with clauses. See PrettyArrows.format_with/2.

Functions

features(opts)

Returns the Mix.Tasks.Format features for this plugin. mix format calls this function, so you don't need to call it yourself.

format(source, opts \\ [])

Formats source and aligns its with clauses. See PrettyArrows.format_with/2.