-
Notifications
You must be signed in to change notification settings - Fork 11.9k
Closed
Description
Bug Report or Feature Request (mark with an x)
- [x ] bug report -> please search issues before submitting
- [ ] feature request
Versions.
@angular/cli: 1.0.4 (e)
node: 6.10.0
os: win32 x64
@angular/common: 4.1.3
@angular/compiler: 4.1.3
@angular/core: 4.1.3
@angular/forms: 4.1.3
@angular/http: 4.1.3
@angular/platform-browser: 4.1.3
@angular/platform-browser-dynamic: 4.1.3
@angular/router: 4.1.3
@angular/cli: 1.0.4
@angular/compiler-cli: 4.1.3
Repro steps.
- Create
example.tsfile insrcdirectory.
// example.ts
import 'rxjs/add/operator/map';
- Add
example.tstoscriptsarray in.angular-cli.json.
// ...
"scripts": [ "example.ts" ],
// ...
- Run
ng servecommand. - Check browser's console.
The log given by the failure.
Uncaught SyntaxError: Unexpected token import
at eval (<anonymous>)
at webpackJsonp.116.module.exports (addScript.js:9)
at Object.107 (example.ts?91e1:1)
at __webpack_require__ (bootstrap 2885b1c…:52)
at Object.247 (addScript.js:10)
at __webpack_require__ (bootstrap 2885b1c…:52)
at webpackJsonpCallback (bootstrap 2885b1c…:23)
at scripts.bundle.js:1
Desired functionality.
TypeScript files added to scripts in .angular-cli.json are transpiled to target ES version.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels