Skip to content

Commit

Permalink
fix(ts-bindings): package.json needs type: module
Browse files Browse the repository at this point in the history
Since we started using `module: nodenext` in tsconfig.json, we need to
tell libraries that import these ones that the exported code is an ES
Module.

This fixes github.com/stellar/soroban-astro-template to work with
libraries generated with `soroban contract bindings typescript`
  • Loading branch information
chadoh committed May 20, 2024
1 parent 8db6145 commit ac46671
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 57 deletions.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -1,17 +1,18 @@
{
"version": "0.0.0",
"name": "INSERT_CONTRACT_NAME_HERE",
"type": "module",
"exports": "./dist/index.js",
"typings": "dist/index.d.ts",
"scripts": {
"build": "tsc"
},
"dependencies": {
"@stellar/freighter-api": "2.0.0",
"buffer": "6.0.3",
"@stellar/stellar-sdk": "12.0.0-rc.3"
},
"scripts": {
"build": "tsc"
},
"exports": "./dist/index.js",
"typings": "dist/index.d.ts",
"devDependencies": {
"typescript": "5.3.3"
}
}
}

0 comments on commit ac46671

Please sign in to comment.