[JsonPolymorphic(TypeDiscriminatorPropertyName = "type")]
[JsonDerivedType(typeof(LocalValue.Number), "number")]
[JsonDerivedType(typeof(LocalValue.String), "string")]
[JsonDerivedType(typeof(LocalValue.Null), "null")]
[JsonDerivedType(typeof(LocalValue.Undefined), "undefined")]
[JsonDerivedType(typeof(LocalValue.Channel), "channel")]
[JsonDerivedType(typeof(LocalValue.Array), "array")]
[JsonDerivedType(typeof(LocalValue.Date), "date")]
[JsonDerivedType(typeof(LocalValue.Map), "map")]
[JsonDerivedType(typeof(LocalValue.Object), "object")]
[JsonDerivedType(typeof(LocalValue.RegExp), "regexp")]
[JsonDerivedType(typeof(LocalValue.Set), "set")]
public abstract record LocalValue : IEquatable<LocalValue>