Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support await in eval and node:vm #14873

Open
TomasHubelbauer opened this issue Oct 28, 2024 · 0 comments
Open

Support await in eval and node:vm #14873

TomasHubelbauer opened this issue Oct 28, 2024 · 0 comments
Labels
enhancement New feature or request node:vm

Comments

@TomasHubelbauer
Copy link

What is the problem this feature would solve?

As of current, neither eval('await 1') nor import { runInNewContext } from 'node:vm'; console.log(await runInNewContext('await (1 + 1)')) work as expected.

I am not surprised to see this not work in Node, but in Bun, it would be ideal if TLA was supported in these contexts and behaved such that the result can be awaited on the call site.

What is the feature you are proposing to solve the problem?

TLA support in the eval method and the methods of the node:vm module.

What alternatives have you considered?

No response

@TomasHubelbauer TomasHubelbauer added the enhancement New feature or request label Oct 28, 2024
@nektro nektro added jsc Something related to JavaScriptCore node:vm labels Oct 28, 2024
@Jarred-Sumner Jarred-Sumner removed the jsc Something related to JavaScriptCore label Oct 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request node:vm
Projects
None yet
Development

No branches or pull requests

3 participants