The background to this is explained in https://gist.github.com/wolfgangwalther/5425d64e7b0d20aad71f6f68474d9f19 This explains the algorithm to transform a pg_node_tree to a JSON format, that can be used by PostgREST to obtain the :targetList of the view.
Author: Wolfgang Walther https://github.com/wolfgangwalther
License: MIT