fix: type should match cjs format#13
Merged
UlisesGascon merged 1 commit intoonebeyond:masterfrom Nov 5, 2025
Merged
Conversation
9 tasks
loveirobert-ob
approved these changes
Nov 5, 2025
UlisesGascon
approved these changes
Nov 5, 2025
Collaborator
|
I will include this change in the next release @albertodeago! Thanks for the fix 👍 |
Contributor
Author
|
Thank you guys for the quick work! 🚀 |
Collaborator
|
Hey @albertodeago should be ready in |
Contributor
Author
|
Amazing, thanks @UlisesGascon 🙏 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Types are not correct, they are not aligned with the code.
Similar to onebeyond/systemic#69
Related Issue
Didn't open an issue, should I do it?
Motivation and Context
This is an issue users encounter if they try to consume this module from an ESM service.
export default runnershould be used if in the js file we were doingexport default runner;-> the package is exported as a ES module.When exporting a CJS module instead (like we're doing here with
module.exports = ...) the type definition should beexport = runner;Typescript is probably clever enough to not raise any error when consuming this in a CJS service, but in an ESM environment it's raising an error, see screenshot

How Has This Been Tested?
This is a change only in the types, I've tried it changing the type definition directly in the node_modules both in a ESM service and in a CJS service
Working in CJS service

Working in ESM service

Types of changes
Checklist: