vdf 1.1.0 copy "vdf: ^1.1.0" to clipboard
vdf: ^1.1.0 copied to clipboard

An encoder and decoder for Valve's KeyValue format (VDF) (https://developer.valvesoftware.com/wiki/KeyValues).

pub package

An encoder and decoder for Valve's KeyValue format (VDF).

Usage #

A VdfCodec encodes input json using Valve's KeyValue format (VDF) and decodes KeyValue string to json.

The vdf is the default implementation of VdfCodec.

Example:

var encoded = vdf.encode({"sampleData":{"foo":"bar"}});

var decoded = vdf.decode(r'''
"sampleData"
{
	"foo"		"bar"
}
''');

You can use shorthands vdfEncode and vdfDecode. Useful if a local variable shadows the global vdf constant:

var encoded = vdfEncode({"sampleData":{"foo":"bar"}});

var decoded = vdfDecode(r'''
"sampleData"
{
	"foo"		"bar"
}
''');

For more information, see also VdfEncoder and VdfDecoder.

6
likes
140
pub points
25%
popularity

Publisher

verified publisheradrianjagielak.dev

An encoder and decoder for Valve's KeyValue format (VDF) (https://developer.valvesoftware.com/wiki/KeyValues).

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (LICENSE)

More

Packages that depend on vdf