10

I need help to find which version of Babel is on my Windows Machine. I have installed it using

npm install --save-dev babel-cli babel-preset-env.

How do I check which version is on my Windows OS?

6 Answers 6

5

After you finish installing Babel, your package.json file should look like this:

{
  "name": "my-project",
  "version": "1.0.0",
  "devDependencies": {
    "babel-cli": "^6.0.0"
  }
}

So you can find your Babel version in this configuration file.

3

Try this at the command line:

npm list babel-cli
2

You can also check the version of babel-cli by finding the babel-cli folder in node_modules and looking at the version property of the package.json that is at the base of that folder.

If babel-cli was installed globally via -g flag of npm install, you could check the version by executing command babel --version.

Hopefully the helps!

2

As the babel is updated to babel 7, check using npm list @babel/cli or npm list @babel/core

1

possibly your local ./node_modules/.bin is not in $PATH check out this previous question for further info.

-1

babel --version

You can figure this out by typing in the command line:

babel --help, look over the output and you can see other options that you might need.

Good luck

Not the answer you're looking for? Browse other questions tagged or ask your own question.