Babel: Transpiling failed: Unexpected token using Bootstrap 4 & Codekit

192 Views Asked by At

I'm trying to minify and transpile (with Babel) Bootstrap 4 with CodeKit3.

However, I'm getting the following error:

Babel: Transpiling failed:

SyntaxError: /bootstrap/carousel.js: Unexpected token (219:8)
  217 |     _getConfig(config) {
  218 |       config = {
> 219 |         ...Default,
      |         ^
  220 |         ...config
  221 |       }
  222 |       Util.typeCheckConfig(NAME, config, DefaultType)

Any idea what this could be?

Here are my settings:

  • Check Syntax with: nothing
  • Transpile with: Babel
  • minify the output
  • generate a source map

Then, within Babel

Enabled presets:

  • ES2017, ES2016, ES2015
1

There are 1 best solutions below

0
Brad Ahrens On

I copied the files in the src folder instead of the dist folder into my project. This seemed to cause the problem.