Hi! I'm currently working on a transpiler for PHP, and we're implementing FFI for standard I/O operations.
Currently, the ecosystem relies heavily on purescript-node-fs (with Node.FS.* modules). To allow existing PureScript code to run on PHP without modification, I had to create a polyfill by mocking this package and its modules, which I forked here.
Having "Node" hardcoded in the module namespaces feels a bit abnormal for alternative backends, even if I truly understand the historical reasons behind. I wonder if there are any long-term plans to create a more agnostic, generic package (e.g., purescript-fs or System.FS) with typeclasses/interfaces, which node-fs, erl-fs or phpurs-fs could then implement?
Just wanted to open the discussion on how alternative backends should gracefully handle these Node-specific namespaces!
Hi! I'm currently working on a transpiler for PHP, and we're implementing FFI for standard I/O operations.
Currently, the ecosystem relies heavily on purescript-node-fs (with Node.FS.* modules). To allow existing PureScript code to run on PHP without modification, I had to create a polyfill by mocking this package and its modules, which I forked here.
Having "Node" hardcoded in the module namespaces feels a bit abnormal for alternative backends, even if I truly understand the historical reasons behind. I wonder if there are any long-term plans to create a more agnostic, generic package (e.g., purescript-fs or System.FS) with typeclasses/interfaces, which node-fs, erl-fs or phpurs-fs could then implement?
Just wanted to open the discussion on how alternative backends should gracefully handle these Node-specific namespaces!