I wrote the code and, opening a page in a browser (Firefox 20.0), I found the following error in the console:
JS: https://unpkg.com/ babel-standalone @ 6 /babel.min.js
TypeError: e.forEach is not a function @ https://unpkg.com/ babel-standalone @ 6 /babel.min.js:8
CODE:
<script type="text/babel">
let input = [1, 2, 3];
console.log(typeof input);
</script>
I noticed that using " let " or " var " does not matter. It falls even until it reaches these lines. Why is this so? Did I miss something?
PS: Although I can use NPM and use a browser to use babel, but I just want to test it using this script.
source
share