Skip to content
Branch: master
Find file History
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
..
Failed to load latest commit information.
app
bin
config
lib
log
public
tmp
vendor
.gitignore
Gemfile
Gemfile.lock
README.md
Rakefile
config.ru
package-lock.json
package.json
webpack.config.js

README.md

Simpacker Babel example

Install packages

$ npm install --save-dev babel-loader @babel/core @babel/preset-env

Edit webpack config

   resolve: {
     extensions: [".js"]
   },
+  module: {
+    rules: [
+      {
+        test: /\.m?js$/,
+        exclude: /node_modules/,
+        use: {
+          loader: "babel-loader",
+          options: {
+            presets: ["@babel/preset-env"]
+          }
+        }
+      }
+    ]
+  },
   plugins: [new WebpackAssetsManifest({ publicPath: true })]
 };
You can’t perform that action at this time.