Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix types #778

Merged
merged 2 commits into from
Aug 18, 2019
Merged

Fix types #778

merged 2 commits into from
Aug 18, 2019

Conversation

hipstersmoothie
Copy link
Collaborator

What's Changing and Why

What else might be affected

Tasks

  • Add tests
  • Update Documentation
  • Update jimp.d.ts
  • Add SemVer Label

@hipstersmoothie hipstersmoothie changed the title test Fix types Aug 17, 2019
@hipstersmoothie hipstersmoothie merged commit 7dff287 into master Aug 18, 2019
@hipstersmoothie hipstersmoothie added the patch Increment the patch version when merged label Sep 2, 2019
@hipstersmoothie
Copy link
Collaborator Author

🚀 PR was released in v0.6.5 🚀

@hipstersmoothie hipstersmoothie added the released This issue/pull request has been released. label Sep 3, 2019
@ffflorian
Copy link

ffflorian commented Sep 3, 2019

The types change was incorrect - there is no default export for jimp.

Try this:

const jimp = require('jimp');
console.log(jimp)

If it would be a default export, it should be visible in the log. Instead, you see this:

[Function: Jimp] {
  AUTO: -1,
  HORIZONTAL_ALIGN_LEFT: 1,
  HORIZONTAL_ALIGN_CENTER: 2,
  HORIZONTAL_ALIGN_RIGHT: 4,
  VERTICAL_ALIGN_TOP: 8,
  VERTICAL_ALIGN_MIDDLE: 16,
  VERTICAL_ALIGN_BOTTOM: 32,
[...]

Edit: It works after setting "esModuleInterop": true in my TSConfig but I had to change all my other imports, too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
patch Increment the patch version when merged released This issue/pull request has been released.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants