FromDocument(string, object) Method
Creates a config value by getting the metadata value of a specified key from a document.
Namespace
Statiq.Common
Containing Type
Config

Syntax

public static Config<object> FromDocument(string key, object defaultValue = null)

Parameters

Name Type Description
key string The metadata key to get the value from.
defaultValue object The default value to use if the key cannot be found or is null.

Return Value

Type Description
Config<object> A config object.