Skip to content

Commit

Permalink
fix bundler to be compatible with commonJS for safe-sdk
Browse files Browse the repository at this point in the history
  • Loading branch information
RnkSngh committed Oct 30, 2024
1 parent 6959fa4 commit bf5862e
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
5 changes: 2 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@open-ibc/vibc-core-smart-contracts",
"version": "4.0.7",
"version": "4.0.8",
"main": "dist/index.js",
"bin": {
"verify-vibc-core-smart-contracts": "./dist/scripts/verify-contract-script.js",
Expand Down Expand Up @@ -103,6 +103,5 @@
"import": "./dist/utils/constants.js",
"types": "./dist/utils/constants.d.ts"
}
},
"type": "module"
}
}
2 changes: 1 addition & 1 deletion src/scripts/update-contracts-script.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ async function main() {
let extraContractFactories: Record<string, object> | null = null;
if (extraBindingsPath) {
try {
extraContractFactories = await import(extraBindingsPath);
extraContractFactories = await require(extraBindingsPath);
} catch (e) {
throw new Error(
`Failed to import extra contract factories from ${extraBindingsPath}: ${e}`
Expand Down
1 change: 1 addition & 0 deletions tsup.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,5 @@ export default defineConfig({
sourcemap: true,
clean: true,
outDir: "./dist",
target: "node18",
});

0 comments on commit bf5862e

Please sign in to comment.