import { esbuild, cache, load } from "./deps.js";const importMap = { imports: {} };const env = await load({ export: true });let envVariables = {};for (const [key, value] of Object.entries(env)) { // That's how esbuild likes it envVariables["process.env." + key] = `"${String(value)}"`;}console.log("Bundling..");esbuild .build({ entryPoints: ["src/mod.js"], bundle: true, format: "esm", outfile: "dist/wallet.js", plugins: [cache({ importMap, directory: "./cache" })], define: envVariables, }) .then(() => { console.log("Bundling Completed"); esbuild.stop(); }) .catch((e) => console.log("Error occured while bundling library: " + e));