react-worker-sandbox
v1.3.0
Published
Display code and run js snippets in a webworker
Downloads
10
Readme
Example how to use it:
import { WorkerSandbox } from 'react-worker-sandbox';
<WorkerSandbox mode="javascript" value={
`for(let i = 0; i < 10; i++) {
console.log(i)
}
console.log('This is a log')
console.warn('This is a warn')
console.error('This is a non-blocking error')
throw new Error('This is a blocking error')
console.log('This will not be displayed')`
}/>