Skip to content

Commit

Permalink
Merge pull request #1006 from o1-labs/fix/commonjs-again
Browse files Browse the repository at this point in the history
Fix CommonJS build
  • Loading branch information
mitschabaude committed Jun 28, 2023
2 parents 71fae9d + 008725a commit 54fbdfc
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 5 deletions.
8 changes: 7 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,16 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
_Security_ in case of vulnerabilities.
-->

## [Unreleased](https://github.com/o1-labs/snarkyjs/compare/2d2af219c...HEAD)
## [Unreleased](https://github.com/o1-labs/snarkyjs/compare/544489609...HEAD)

> No unreleased changes yet
## [0.11.3](https://github.com/o1-labs/snarkyjs/compare/2d2af219c...544489609)

### Fixed

- Fix commonJS version of SnarkyJS, again https://github.com/o1-labs/snarkyjs/pull/1006

## [0.11.2](https://github.com/o1-labs/snarkyjs/compare/c549e02fa...2d2af219c)

### Fixed
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

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

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "snarkyjs",
"description": "TypeScript framework for zk-SNARKs and zkApps",
"version": "0.11.2",
"version": "0.11.3",
"license": "Apache-2.0",
"homepage": "https://github.com/o1-labs/snarkyjs/",
"keywords": [
Expand Down
7 changes: 6 additions & 1 deletion src/build/buildNode.js
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,12 @@ function makeJsooExternal() {
name: 'plugin-external',
setup(build) {
build.onResolve({ filter: isJsoo }, ({ path: filePath, resolveDir }) => ({
path: path.resolve(resolveDir, filePath),
path:
'./' +
path.relative(
path.resolve('.', 'dist/node'),
path.resolve(resolveDir, filePath)
),
external: true,
}));
},
Expand Down

0 comments on commit 54fbdfc

Please sign in to comment.