mirror of
https://git.proxmox.com/git/mirror_novnc
synced 2025-04-29 00:12:27 +00:00

There has been a lot of renaming and restructuring in babel, so we need to modify our code to handle the latest version. We also need to adjust the way we build our babel worker as babel itself no longer runs in older browsers such as Internet Explorer.
14 lines
349 B
JavaScript
Executable File
14 lines
349 B
JavaScript
Executable File
#!/usr/bin/env node
|
|
|
|
var fs = require("fs");
|
|
var browserify = require("browserify");
|
|
|
|
browserify("src/babel-worker.js")
|
|
.transform("babelify", {
|
|
presets: [ [ "@babel/preset-env", { targets: "ie >= 11" } ] ],
|
|
global: true,
|
|
ignore: [ "../../node_modules/core-js" ]
|
|
})
|
|
.bundle()
|
|
.pipe(fs.createWriteStream("dist/babel-worker.js"));
|