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

Bug: Package exports do not define a valid '.' target #51

Closed
Komaricus opened this issue Aug 13, 2020 · 2 comments
Closed

Bug: Package exports do not define a valid '.' target #51

Komaricus opened this issue Aug 13, 2020 · 2 comments

Comments

@Komaricus
Copy link

Komaricus commented Aug 13, 2020

Hi!

Trying to create new Vue application with vue-cli command vue create brief-vue and then run and got an error:

Error: Package exports for '/Users/aleksandr/Documents/brief-vue/node_modules/colorette' do not define a valid '.' target
Error: Package exports for '/Users/aleksandr/Documents/brief-vue/node_modules/colorette' do not define a valid '.' target
    at resolveExportsTarget (internal/modules/cjs/loader.js:545:13)
    at applyExports (internal/modules/cjs/loader.js:459:14)
    at resolveExports (internal/modules/cjs/loader.js:508:12)
    at Function.Module._findPath (internal/modules/cjs/loader.js:577:20)
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:879:27)
    at Function.Module._load (internal/modules/cjs/loader.js:785:27)
    at Module.require (internal/modules/cjs/loader.js:956:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at Object.<anonymous> (/Users/aleksandr/Documents/brief-vue/node_modules/autoprefixer/lib/autoprefixer.js:5:17)
    at Module._compile (internal/modules/cjs/loader.js:1063:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1103:10)
    at Module.load (internal/modules/cjs/loader.js:914:32)
    at Function.Module._load (internal/modules/cjs/loader.js:822:14)
    at Module.require (internal/modules/cjs/loader.js:956:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at /Users/aleksandr/Documents/brief-vue/node_modules/@vue/cli-service/lib/config/css.js:87:11
error Command failed with exit code 1.

Seems like the required file is missing: https://github.com/jorgebucaran/colorette/blob/master/package.json#L18

In my node_modules:

image

Your .gitignore file:
image

My setup:
macOS Catalina 10.15.6
yarn 1.22.4
node v14.8.0
@vue/cli 4.5.3

@Komaricus Komaricus changed the title Package exports do not define a valid '.' target Bug: Package exports do not define a valid '.' target Aug 13, 2020
@jorgebucaran
Copy link
Owner

jorgebucaran commented Aug 13, 2020

Hey @Komaricus, are you completely sure this is not a Node.js version related issue? #48 nodejs/modules#446

@Komaricus
Copy link
Author

Thanks, upgrading node and nvm use 14.8 already helped me

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