This commit is contained in:
GitLab Deploy Bot
2025-10-21 23:45:13 +07:00
committed by Adnan Zahir
parent d41e16cab9
commit ad815b3412
3546 changed files with 4952546 additions and 30 deletions
+16
View File
@@ -0,0 +1,16 @@
package toml
import (
"github.com/pelletier/go-toml/v2"
)
// Codec implements the encoding.Encoder and encoding.Decoder interfaces for TOML encoding.
type Codec struct{}
func (Codec) Encode(v map[string]any) ([]byte, error) {
return toml.Marshal(v)
}
func (Codec) Decode(b []byte, v map[string]any) error {
return toml.Unmarshal(b, &v)
}