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

NPM package.json missing "main" definition #25

Closed
niekvb opened this issue Feb 19, 2022 · 2 comments
Closed

NPM package.json missing "main" definition #25

niekvb opened this issue Feb 19, 2022 · 2 comments

Comments

@niekvb
Copy link

niekvb commented Feb 19, 2022

When using the TypeScript library I ran into the following error:

Module not found: Error: Can't resolve '@material/material-color-utilities' in '...'

This is due to the following line missing in package.json:

"main": "./dist/index.js",

This in package version 0.1.1

@ausov
Copy link

ausov commented Feb 26, 2022

FYI, as a workaround for webpack@4 you can try an alias:

resolve: {
  alias: {
     '@material/material-color-utilities': '@material/material-color-utilities/dist/index.js'
  }
}

@ausov
Copy link

ausov commented Mar 18, 2022

See also #1

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

No branches or pull requests

2 participants