pinojs / thread-stream

A streaming way to send data to a Node.js Worker Thread
MIT License
229 stars 23 forks source link

fix explicit default export for yarn pnp cjs fallback #89

Closed andrew0 closed 2 years ago

andrew0 commented 2 years ago

Currently, the require fallback for Yarn PnP mode does not check for a default property, so it does not work for TypeScript modules using the export default syntax if they're transpiled to commonjs. Moving the default property check after the fallback fixes this.

mcollina commented 2 years ago

Apparently this is failing: https://github.com/pinojs/thread-stream/runs/7151031795?check_suite_focus=true.