Documentation ¶
Overview ¶
Package format implements formatting of Rego source files.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Ast ¶
Ast formats a Rego AST element. If the passed value is not a valid AST element, Ast returns nil and an error. Ast relies on all AST elements having non-nil Location values. If an AST element with a nil Location value is encountered, a default location will be set on the AST node.
func Bytes ¶
Bytes formats Rego source code. The bytes provided do not have to be an entire source file, but they must be parse-able. If the bytes are not parse-able, Bytes will return an error resulting from the attempt to parse them.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.