hoppscotch/packages/hoppscotch-js-sandbox
Muhammed Ajmal M 4cba03e53f
feat(js-sandbox): add pw.env.unset method (#3677)
Co-authored-by: jamesgeorge007 <jamesgeorge998001@gmail.com>
2024-01-23 22:31:27 +05:30
..
src feat(js-sandbox): add pw.env.unset method (#3677) 2024-01-23 22:31:27 +05:30
.eslintrc.cjs
.gitignore
.prettierignore
.prettierrc.cjs
index.d.ts refactor(scripting-revamp): migrate js-sandbox to web worker/Node vm based implementation (#3619) 2023-12-07 16:10:42 +05:30
jest.config.js refactor(scripting-revamp): migrate js-sandbox to web worker/Node vm based implementation (#3619) 2023-12-07 16:10:42 +05:30
jest.setup.ts
node.d.ts refactor(scripting-revamp): migrate js-sandbox to web worker/Node vm based implementation (#3619) 2023-12-07 16:10:42 +05:30
package.json refactor(scripting-revamp): migrate js-sandbox to web worker/Node vm based implementation (#3619) 2023-12-07 16:10:42 +05:30
README.md
tsconfig.json refactor(scripting-revamp): migrate js-sandbox to web worker/Node vm based implementation (#3619) 2023-12-07 16:10:42 +05:30
vite.config.ts refactor(scripting-revamp): migrate js-sandbox to web worker/Node vm based implementation (#3619) 2023-12-07 16:10:42 +05:30
web.d.ts refactor(scripting-revamp): migrate js-sandbox to web worker/Node vm based implementation (#3619) 2023-12-07 16:10:42 +05:30

Hoppscotch JavaScript Sandbox ALPHA

This package deals with providing a JavaScript sandbox for executing various security sensitive external scripts.

How does this work?

This package makes use of quickjs-emscripten for building sandboxes for running external code on Hoppscotch.

Currently implemented sandboxes:

  • Hoppscotch Test Scripts
  • Hoppscotch Pre Request Scripts

Development

  1. Clone the repository
git clone https://github.com/hoppscotch/hoppscotch
  1. Install the package dependencies
pnpm install
  1. Navigate to the package folder
cd hoppscotch/packages/hoppscotch-js-sandbox
  1. Try out the demo src/demo.ts using:
npm run demo

Versioning

This project follows Semantic Versioning but as the project is still pre-1.0. The code and the public exposed API should not be considered to be fixed and stable. Things can change at any time!

License

This project is licensed under the MIT License - see LICENSE for more details.



built with ❤︎ by the Hoppscotch Team and contributors.