Revert exports to match 0.6.4 TS definitions #820
Merged
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.
What's Changing and Why
Many developers using TypeScript have reported that 0.6.4 was the last time that they were able to use the TypeScript definition files. This is because in 0.6.5 the
export
format was modified to more accurately fall inline with ESModule export syntax.While TypeScript compiler, with some settings, allow you to handle this export and have the correct results, if the project feels it better to use the same exports as 0.6.4, this is how it would be done without removing the additional types from missing plugins, removing the TS type tests, and more
What else might be affected
This would be a breaking change from the current (or even the version 0.6.5) definition files as we no longer export interfaces such as
Bitmap
or others. This is because thisexport = Object
does not allow for any other exports to be named in a definition file. Needless to say, someone is not going to be happy with the typings regardless of what we do. I'm just opening this PR per #803 (comment) as it seems like this is the direction we want to go inTasks
jimp.d.ts