Enhance Vite configuration and improve memory usage checks#621
Draft
Kolezhniuk wants to merge 5 commits intofeature/memory-scopingfrom
Draft
Enhance Vite configuration and improve memory usage checks#621Kolezhniuk wants to merge 5 commits intofeature/memory-scopingfrom
Kolezhniuk wants to merge 5 commits intofeature/memory-scopingfrom
Conversation
refactor: change logger parameter to unused in exportFFlonkVk function fix: initialize variables pB and pS in zkey_new.js style: format code for consistency in witness_calculator.cjs test: update test timeouts to use beforeAll and afterAll hooks feat: add Groth16 test suite for zkSNARK verification feat: implement smart contract verifiers for Groth16, PLONK, and FFlonk chore: add Vite configuration for building and testing
- Updated memory usage functions in `groth16_prove.js` and `zkey_new.js` to handle cases where the process object is undefined, ensuring compatibility in non-Node environments. - Modified `vite.config.js` to exclude certain Node-only files from browser builds, preventing unnecessary dependencies from being included in the bundle. - Added a plugin to stub Node-only modules, allowing for cleaner builds and avoiding errors related to missing modules in the browser context. - Disabled minification in the browser build for easier debugging and added rollup options to manage external dependencies more effectively.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request makes significant changes to the project's build system, testing setup, and configuration files, focusing on modernizing the toolchain, removing legacy and redundant files, and improving developer experience. The most important changes are the migration from Rollup to Vite for builds, switching from Mocha to Vitest for testing, updating ESLint configuration, and cleaning up old test and config files.
Build system modernization:
package.jsonto use Vite commands for building Node, CLI, browser, and IIFE bundles. The old Rollup config files were removed. [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] [12] [13] [14] [15]Testing and CI improvements:
browser_testsandsmart_contract_testssubprojects, including their configs, scripts, and dependencies, consolidating all tests under the main project. [1] [2] [3] [4] [5]Linting and configuration updates:
eslint.config.js, using the latest ESLint and@eslint/js, and updated ignored paths and rules. The old.eslintrc.cjswas removed. [1] [2]@noble/hashes,ffjavascript, and others.General project cleanup:
0.7.6-pocand adjusted theexportsfield inpackage.jsonfor better module resolution. [1] [2]Smart contract testing update:
These updates collectively modernize the development workflow, improve maintainability, and streamline the project's configuration and testing infrastructure.