Skip to content
New issue

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

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

Already on GitHub? # to your account

Starter doesn't work with Module build failed: Error: Couldn't find preset "env" relative to directory home/<user> #3756

Closed
geyang opened this issue Jan 28, 2018 · 4 comments

Comments

@geyang
Copy link

geyang commented Jan 28, 2018

Description

install gatsby, do gatsby create new-site. go in new-site and do gatsby develop, gives following error:

Module build failed: Error: Couldn't find preset "env" relative to directory

Environment

Gatsby version: newest
Node.js version: 9.3.0
Operating System: macOS 10.13.3

File contents (if changed):

nothing changed. Directly from create.

Dear community, what is the problem here? I don't want to install babel-preset-env globally. I use it with every project, but I just do local install since this way it is easy to prevent this kind of bug in my projects.

It seems that gatsby requires babel-preset-env globally?

@tsriram
Copy link
Contributor

tsriram commented Jan 29, 2018

I could not reproduce this issue with same versions of Gatsby & Node on Ubuntu. Can you try with a starter explicitly like mentioned in #2092 and see if it works?

@ATwrx
Copy link

ATwrx commented Jul 21, 2018

Removing a global babel config from my home folder fixed it for me.
OS: Manjaro Linux

@JMV2112
Copy link

JMV2112 commented Jul 24, 2018

I can confirm that removing my projects .bablerc file fixed the problem for me as I migrate from v1 to v2.

@KyleAMathews
Copy link
Contributor

Due to the high volume of issues, we're closing out older ones without recent activity. Please open a new issue if you need help!

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants