diff --git a/gulp/babel-es6.config.js b/gulp/babel-es6.config.js index 765cb1f3..b0bb02c4 100644 --- a/gulp/babel-es6.config.js +++ b/gulp/babel-es6.config.js @@ -14,6 +14,8 @@ module.exports = function (api) { ], ]; const plugins = [ + ["@babel/plugin-proposal-class-properties", { loose: true }], + "closure-elimination", // var is faster than let and const! [ @@ -28,7 +30,6 @@ module.exports = function (api) { loose: true, }, ], - [require("@babel/plugin-proposal-class-properties"), { loose: true }], ]; return { presets, diff --git a/gulp/babel.config.js b/gulp/babel.config.js index 924ad0a1..f8785737 100644 --- a/gulp/babel.config.js +++ b/gulp/babel.config.js @@ -14,6 +14,8 @@ module.exports = function (api) { ], ]; const plugins = [ + ["@babel/plugin-proposal-class-properties", { loose: true }], + "closure-elimination", // var is faster than let and const! [ @@ -28,7 +30,6 @@ module.exports = function (api) { loose: true, }, ], - [require("@babel/plugin-proposal-class-properties"), { loose: true }], ]; return { presets, diff --git a/src/js/game/components/wire.js b/src/js/game/components/wire.js index 931c5429..c3ed4141 100644 --- a/src/js/game/components/wire.js +++ b/src/js/game/components/wire.js @@ -1,4 +1,7 @@ +/* typehints:start */ import { MetaWireBuilding } from "../buildings/wire"; +/* typehints:end */ + import { Component } from "../component"; /** @enum {string} */