Tired of using boring #Go fmt
package?
Try the latest Go Formatter package today. It implements replacement fields surrounded by curly braces {}
format strings similar to Python string format.
Features:
- Implements replacement fields surrounded by curly braces
{}
format strings - Format string by providing arguments without using placeholders or format verbs
%
- Format string using automatic placeholder
{p}
- Format string using positional placeholders
{pN}
- Format string using named placeholders
{name}
- Format string using object placeholders
{.Field}
,{p.Field}
and{pN.Field}
whereField
is an exportedstruct
field or method - Use custom placeholder string. Default is
p
- Use custom replacement delimiters. Default are
{
and}
- Use custom replacement functions with transformation using pipeline
|
- Under the hood it uses the standard text/template package
Top comments (0)