1
0
Fork 1
mirror of https://github.com/maunium/stickerpicker synced 2024-11-09 03:44:10 +00:00
stickerpicker/web/esinstall.js
2021-10-03 12:42:11 +03:00

23 lines
557 B
JavaScript

const { install, printStats } = require("esinstall")
install(
[{
specifier: "htm/preact",
all: false,
default: false,
namespace: false,
named: ["html", "render", "Component"],
}],
{
dest: "./lib",
sourceMap: false,
treeshake: true,
verbose: true,
}
).then(data => {
const oldPrefix = "web_modules/"
const newPrefix = "lib/"
const spaces = " ".repeat(oldPrefix.length - newPrefix.length)
console.log("Installation complete")
console.log(printStats(data.stats).replace(oldPrefix, newPrefix + spaces))
})