Closed
Description
Version
3.2.1
Environment info
Environment Info:
System:
OS: Windows 10
CPU: (12) x64 AMD Ryzen 5 1600 Six-Core Processor
Binaries:
Node: Not Found
Yarn: Not Found
npm: 6.4.1 - C:\Program Files\nodejs\npm.CMD
Browsers:
Edge: Not Found
npmPackages:
@vue/cli-overlay: 3.2.0
@vue/cli-plugin-typescript: ^3.2.0 => 3.2.0
@vue/cli-service: ^3.2.0 => 3.2.0
@vue/cli-shared-utils: 3.2.0
@vue/component-compiler-utils: 2.3.1
@vue/preload-webpack-plugin: 1.1.0
@vue/web-component-wrapper: 1.2.0
vue: ^2.5.17 => 2.5.21
vue-class-component: ^6.0.0 => 6.3.2
vue-hot-reload-api: 2.3.1
vue-loader: 15.4.2
vue-property-decorator: ^7.0.0 => 7.2.0
vue-router: ^3.0.1 => 3.0.2
vue-style-loader: 4.1.2
vue-template-compiler: ^2.5.17 => 2.5.21
vue-template-es2015-compiler: 1.6.0
vuex: ^3.0.1 => 3.0.1
npmGlobalPackages:
@vue/cli: Not Found
Steps to reproduce
vue-cli-service build --modern
What is expected?
It should compile to ES2015
What is actually happening?
It doesn't compile to ES2015 because you have to modify the .tsconfig target.
The target option in tsconfig is absolute, meaning if target: es2018 or if target:es2015, all code will be transpiled to said target in tsconfig regardless of --modern flag being used or not. This should be reflected in the docs or warn when using typescript.