-
Notifications
You must be signed in to change notification settings - Fork 3
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
fix: used monaco compiler options latest #913
fix: used monaco compiler options latest #913
Conversation
monaco.languages.typescript.typescriptDefaults.setCompilerOptions({ | ||
target: monaco.languages.typescript.ScriptTarget.ES2016, | ||
target: monaco.languages.typescript.ScriptTarget.Latest, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
print: monaco.languages.typescript.ScriptTarget
{
"0": "ES3",
"1": "ES5",
"2": "ES2015",
"3": "ES2016",
"4": "ES2017",
"5": "ES2018",
"6": "ES2019",
"7": "ES2020",
"99": "Latest",
"100": "JSON",
"ES3": 0,
"ES5": 1,
"ES2015": 2,
"ES2016": 3,
"ES2017": 4,
"ES2018": 5,
"ES2019": 6,
"ES2020": 7,
"ESNext": 99,
"JSON": 100,
"Latest": 99
}
Are there any issues where setting to the latest compiler options can be harmful? |
So the backend runs with a target of es2018 and a runtime of 2021. I'm not totally sure of the difference, even with the comments there. But in any case, that's what we use. I would say maybe we should match them. I'm not clear on what the differences between the versions are, but I would surmise there's at least some, if not significant, differences. Since we use VM2 under the hood, we're kinda forced to be stuck with specific Node/TS/etc. versions. So, perhaps we can stick to either 2018 or 2021. |
Sorry this got lost in the sprint cycle from last week. I modified the monaco editor to run in 2018 to match the backend. ES2021 may introduce discrepancies with the backend. regardless .entries got introduced in 2017 so either work. |
fix: Set monaco compiler options to latest