From ff3d8ed6eba63898cf78e51291ba648d826821d4 Mon Sep 17 00:00:00 2001 From: Marcel Laverdet Date: Fri, 12 Jul 2024 12:28:00 -0400 Subject: [PATCH] Update issue template --- ISSUE_TEMPLATE.md | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/ISSUE_TEMPLATE.md b/ISSUE_TEMPLATE.md index 7abaf5f..27c0642 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"')); +```