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

Couldn't find babel or babel-core #171

Closed
floriandotorg opened this issue Aug 31, 2015 · 6 comments
Closed

Couldn't find babel or babel-core #171

floriandotorg opened this issue Aug 31, 2015 · 6 comments

Comments

@floriandotorg
Copy link

Hi,

I'm constantly getting "Couldn't find babel or babel-core" when I try to transform a file.
Babel as well as babel-ore are globally installed.

@sunglee
Copy link

sunglee commented Sep 4, 2015

Check you have babel in your /node_modules/ path. If not,

npm install -g babel

sudo if you need.

@zertosh
Copy link
Member

zertosh commented Sep 4, 2015

I haven't added this to the README yet, but this comment should help you understand what babel is actually used #130 (comment)

@floriandotorg
Copy link
Author

Hi, sorry, forgot to mention, of course I did install babel.

But I guess this happens because I'm using NVM, so my packages lying under ~/.nvm/versions/v0.12.7/lib/node_modules

@zertosh
Copy link
Member

zertosh commented Sep 8, 2015

@floriandotorg when it comes to looking for a global babel install, it looks in the standard places – so not in the nvm directory. You can specify the node_modules path in your Babel.sublime-settings. I should really document all of this 😞

@danesparza
Copy link

I'm on Windows 7, and I had to:

  • first do an npm install -g babel (of course)
  • get the path that %AppData%\npm\node_modules mapped to. For me, this path ended up being C:/Users/myusername_here/AppData/Roaming/npm/node_modules. Note the use of forward slashes.
  • Take this path and place it in the Babel.sublime-settings file. This is pretty easy to spot by going into Sublime -> Preferences -> Package Settings -> Babel -> Settings - Default
  • Restart sublime (this might have just been my superstition).
  • Open a React flavored .js file and select Tools -> Babel -> Babel Transform
  • Enjoy your transformed file!

@zertosh
Copy link
Member

zertosh commented Nov 27, 2016

This functionality is going away soon. See #293.

@zertosh zertosh closed this as completed Nov 27, 2016
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

4 participants