I have some custom predicates
I connect them in configure
block
Then i try write this
optional(:items).value(:array?, min_size?: 1) do
each do
schema do
required(:name).filled(:str?)
required(:price).filled(:amount_format?, :amount_value?, :amount_currency?)
required(:tax_type).filled(:str?, included_in?: Types::TaxTypes.values)
optional(:quantity).filled(:int?)
end
end
end
I have error -
`raise_unknown_predicate_error': +amount_format?+ is not a valid predicate name (ArgumentError)
I think, because i connect my predicates in configure
block - when validation parse this rule - it don’t know about custom predicates
Question - how i can use custom predicates in deep validation block?