How to compute tangent vectors on facets (2D surface parametrization)

The XDMFFile format has not written anything other than first order continuous interpolations for a very long time. As stated in: Cannot write function to XDMF with DG elements - #2 by dokken with XDMFFile there was an implicit interpolation step into continuous Lagrange prior to storing it.