-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Set esbuild target as node12 #10061
Set esbuild target as node12 #10061
Conversation
We just removed a workaround for Node 12 in #10053, as the official policy is to support the latest two VS Code releases. Is Theia planning to rebase on top of a newer Code version (looks like it's on 1.45 currently)? Do we really want to commit to supporting Node 12 indefinitely? |
@lnicola Thank you for pointing out.
Probably the PR will be released on the end of Sep. It may be postponed though, I think we don't need to support indefinitely. |
Yeah, I'd rather put the pressure on upstream to update, rather than maintain compatibility downstream. We do need to say |
As a remainder, in this kinds of situation there's always an option of using an older version -- it's not that rust-analyzer won't support theia at all, it's just that theia users would have to use an older version of rust-analyzer. |
10062: Set esbuild target as node14 r=matklad a=mtsmfm ref: #10061 Currently, target version is not specified so it's esnext. https://esbuild.github.io/api/#target VSCode uses node 14 since version 1.56. #3167 (comment) Co-authored-by: Fumiaki MATSUSHIMA <mtsmfm@gmail.com>
OK, I sent another PR to set target explicitly. As a personal (and for theia users) memo, probably 2021-08-09 is the last version which supports nodejs 12 because previously tsc is used and its target is es2019 https://github.com/rust-analyzer/rust-analyzer/releases/tag/2021-08-09 |
@lnicola I'm not familiar with Open VSX though, I don't think it's related to Theia. |
Note that we are only removing unnecessary constraints on the upper bound Node version: we concluded that we should limit ourselves to using Node.js 12 JS API only (at least for now), this way adopters should be able to use any Node.js version >=12 thanks to backward compatibility of the Node.js APIs. But what this issue shows me is that we can't really expect VS Code extension developers to limit themselves to older Node.js APIs, it only makes sense to align with VS Code's runtime (node 14 here). Regarding your current configuration, as VS Code runs on Node.js 14 I don't think |
I assume Theia will have to move on in April, when Node 12 goes EOL. As for |
Currently, target version is not specified so it's
esnext
.https://esbuild.github.io/api/#target
As a result, generated file is not valid for node12, the node version which is used by theia editor.
https://github.com/eclipse-theia/theia/blob/02261581de60f5221de6264fab4b011c51e5ab91/package.json#L7