@jayway/getsandbox-express
v1.5.0
Published
getsandbox-express adapter and cli
Downloads
3
Keywords
Readme
@jayway/getsandbox-express
A getsandbox.com to express adapter
Usage
as command-line tool, without installing
npx @jayway/getsandbox-express <main.js> [<port>]
Alternatively, if you want to install it globally:
npm install -g @jayway/getsandbox-express
sandbox <main.js> [<port>]
Default port is 8080
.
as Node.js module
const sandbox = require('@jayway/getsandbox-express')
const express = require('express')
const app = express()
sandbox.loadSandbox(app, __dirname + '/mysandbox/main.js')
const port = 8080
app.listen(port, () => {
console.log(`Sandbox listening on port ${port}.`)
})