diff --git a/ISSUE_TEMPLATE.md b/ISSUE_TEMPLATE.md index 7abaf5fc..27c06425 100644 --- a/ISSUE_TEMPLATE.md +++ b/ISSUE_TEMPLATE.md @@ -8,3 +8,32 @@ If some specific code is triggering the issue then please include a FULL EXAMPLE can be run on its own. Please no "snippets", if I can't run the code without modifications then I can't help you. --> + +## Is Your Question Already Answered? +- [ ] I have read the [Frequently Asked Question](https://github.com/laverdet/isolated-vm?tab=readme-ov-file#frequently-asked-question) in the README. My question is not the Frequently Asked Question. + +## Personal Diagnostics +Please answer the following questions: + +#### JavaScript includes a `setTimeout` function: +- [ ] Yes +- [ ] No + +#### Functions are a type of primitive value in JavaScript: +- [ ] Yes +- [ ] No + +#### Objects can be shared between isolates: +- [ ] Yes +- [ ] No + +## The Code +- [ ] This code will parse and evaluate if I put it into a file called `main.mjs` and then run `node main.mjs`. + +```js +// Replace this code with the code which demonstrates what you are asking about +import ivm from "isolated-vm"; +const isolate = new ivm.Isolate(); +const context = await isolate.createContext(); +console.log(await context.eval('"hello world"')); +```