I think the problem to your solution can be done via the methodology stated at: https://blog.stdlib.io/how-to-call-fortran-routines-from-javascript-with-node-js/