I wanted to add a comment, but I need to have 50 reputation and I don't have it. This is unfortunately not an answer, but I wanted to ask if you got any far in this problem. I am also trying to register custom transforms, but the process is too obscure, and Vega documentation does not help at all. I've found two interesting examples: https://github.com/mitvis/vl-animation/tree/main this one, where a prototype compiler for vega is built and even custom functions are defined in src/compile.ts; and this other one, that implements a custom transform: https://github.com/vega/vega-plus/tree/master/packages/vega-plus-core However, even with both examples, the process seems very obscure to me. Did you manage to go past this problem? Thanks.