PureScript FFI and JavaScript module formats: verifying runtime representations across compiler versions
PureScript compiles to JavaScript and exposes host functions through foreign import , but the FFI boundary is untyped: PureScript's erased types become plain objects at runtime, and JavaScript consumers cannot rely on compile-time guarantees. The compiler can emit different JavaScript module formats, such as CommonJS and ES modules, which determines how Node