diff --git a/.changeset/wicked-pillows-behave.md b/.changeset/wicked-pillows-behave.md new file mode 100644 index 000000000..8eae313a0 --- /dev/null +++ b/.changeset/wicked-pillows-behave.md @@ -0,0 +1,5 @@ +--- +"thirdweb": patch +--- + +fix the build (ESM package) diff --git a/packages/cli/src/cli/index.ts b/packages/cli/src/cli/index.ts index ae39f3c7e..5809e49b6 100644 --- a/packages/cli/src/cli/index.ts +++ b/packages/cli/src/cli/index.ts @@ -9,7 +9,6 @@ import generateDashboardUrl from "../helpers/generate-dashboard-url"; import chalk from "chalk"; import { Command } from "commander"; import open from "open"; -import updateNotifier from "update-notifier"; const main = async () => { const program = new Command(); @@ -25,12 +24,14 @@ $$$$$$\\ $$$$$$$\\ $$\\ $$$$$$\\ $$$$$$$ |$$\\ $$\\ $$\\ $$$$$$\\ $$$$ \\$$$$ |$$ | $$ |$$ |$$ | \\$$$$$$$ |\\$$$$$\\$$$$ |\\$$$$$$$\\ $$$$$$$ | \\____/ \\__| \\__|\\__|\\__| \\_______| \\_____\\____/ \\_______|\\_______/ `); console.info(`\n 💎 thirdweb-cli v${cliVersion} 💎\n`); - updateNotifier({ - pkg, - shouldNotifyInNpmScript: true, - //check every time while we're still building the CLI - updateCheckInterval: 0, - }).notify(); + import("update-notifier").then(({ default: updateNotifier }) => { + updateNotifier({ + pkg, + shouldNotifyInNpmScript: true, + //check every time while we're still building the CLI + updateCheckInterval: 0, + }).notify(); + }); program .name("thirdweb-cli")