atproto_codegen/emit/exprs
Per-field expressions: the Gleam type, encoder, and decoder for one lexicon field type, plus the predicates the header/emission logic keys on.
Values
pub fn decoder_expr(
cfg: config.Config,
current: String,
union_name: String,
ft: lexicon.FieldType,
) -> String
pub fn encoder_expr(
cfg: config.Config,
current: String,
union_name: String,
ft: lexicon.FieldType,
) -> String
pub fn escape(value: String) -> String
pub fn gleam_type(
cfg: config.Config,
current: String,
union_name: String,
ft: lexicon.FieldType,
) -> String
pub fn type_uses_blob(ft: lexicon.FieldType) -> Bool
pub fn type_uses_helper(ft: lexicon.FieldType) -> Bool
pub fn type_uses_unknown(ft: lexicon.FieldType) -> Bool
pub fn union_of(
ft: lexicon.FieldType,
) -> option.Option(List(String))
pub fn union_type_name(
cfg: config.Config,
def: lexicon.Def,
prop: lexicon.Property,
) -> String
The synthesized name for a property’s inline union type.