I\'m trying to use ES6 in a Google Spreadsheet (in the script.google.com part). I\'m pretty new to JavaScript and maybe the error is trivial ...
Update as on 2018:
If you are craving for modern Javascript within GAS, you can either use Webpack as described by James or if you are comfortable using Typescript, you can use clasp for this.
Clasp is an official GAS deployment toolkit that lets you to develop your Apps Script projects locally and deploy it to Apps Script when you're done. Since the code is local, you can use your favorite IDE and development tools like git when building Apps Script projects.