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: node 16 module resolution error #3589

Merged
merged 1 commit into from
Jul 9, 2023

Conversation

bsssshhhhhhh
Copy link
Contributor

Description

Adds a "types" field to the exports block in package.json to allow TypeScript's Node16 resolution to work properly.

Without it, TypeScript throws this error:

Could not find a declaration file for module 'vuestic-ui'. '/workspace/node_modules/vuestic-ui/dist/es/main.js' implicitly has an 'any' type.
  There are types at '/workspace/node_modules/vuestic-ui/dist/types/main.d.ts', but this result could not be resolved when respecting package.json "exports". The 'vuestic-ui' library may need to update its package.json or typings

Markup:

// Your code

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Improvement/refactoring (non-breaking change that doesn't add any feature but make things better)

@m0ksem m0ksem changed the title Fix Node16 module resolution error fix: node 16 module resolution error Jul 9, 2023
Copy link
Collaborator

@m0ksem m0ksem left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@m0ksem m0ksem merged commit 755c3c2 into epicmaxco:develop Jul 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants