When running tsc --init --target es2015, the generated target is es6.
{
"compilerOptions": {
/* Visit https://aka.ms/tsconfig.json to read more about this file */
/* Basic Options */
// "incremental": true, /* Enable incremental compilation */
"target": "es6" /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019', 'ES2020', or 'ESNEXT'. */
}
This is unfortunate as the generated file looks as if it was having an invalid option.
🔎 Search Terms
tsc init es2015 es6
🕗 Version & Regression Information
I'm using tsc 4.2.4, and replicated with tsc 4.4.0-dev.20210518
I was unable to test this on prior versions because I don't think this is an actual regression. I found b871b5353c8a9ca6dedd6bc84706fd75ed86bae4, and I suspect that this is a left-over.
Bug Report
When running
tsc --init --target es2015
, the generated target ises6
.This is unfortunate as the generated file looks as if it was having an invalid option.
🔎 Search Terms
tsc init es2015 es6
🕗 Version & Regression Information
I'm using tsc 4.2.4, and replicated with tsc 4.4.0-dev.20210518
🙁 Actual behavior
🙂 Expected behavior