Skip to content

JsonDocumentOptions

Definition

Namespace: Corvus.Text.Json
Assembly: Corvus.Text.Json.dll
Source: JsonDocumentOptions.cs

Provides the ability for the user to define custom behavior when parsing JSON to create a JsonDocument.

public readonly struct JsonDocumentOptions

Properties

Property Type Description
AllowTrailingCommas bool Defines whether an extra comma at the end of a list of JSON values in an object or array is allowed (and ignored) within the JSON payload being read.
CommentHandling JsonCommentHandling Defines how the Utf8JsonReader should handle comments when reading through the JSON.
MaxDepth int Gets or sets the maximum depth allowed when reading JSON, with the default (i.e. 0) indicating a max depth of 64.

Applies To

Product Versions
.NET 9, 10
.NET Standard 2.0, 2.1

Collaborate with us on GitHub

The source for this content can be found on GitHub, where you can also create and review issues and pull requests.

Open an issue