talira

YamlDotNet

YAML parser, emitter and serializer for .NET

open sourceMITfree

YamlDotNet is a YAML library for .NET. It parses and emits YAML at a low level, offers a high-level object model like XmlDocument, and includes a serializer that reads and writes .NET objects from and to YAML streams, with configurable naming conventions. Its parser conforms to YAML 1.1 and 1.2 and its emitter to 1.1. It targets netstandard 2.0 and 2.1, .NET 8 and 10 and .NET Framework 4.7, and is also sold for Unity on the Unity Asset Store. Its author is Antoine Aubry.

Problems it solves

  • read a YAML config file into C# objects
  • write .NET objects out as YAML
  • parse YAML in a .NET app without a full document model

Features

  • Serialize .NET objects to YAML and deserialize them back
  • Configurable naming conventions such as camelCase
  • Low-level YAML parser and emitter
  • High-level object model similar to XmlDocument
  • Parser conforms to YAML 1.1 and 1.2
  • netstandard 2.0 and 2.1, .NET 8 and 10, .NET Framework 4.7

Limitations

  • Its emitter conforms to YAML 1.1 only, not 1.2.1