# SyntaxError: Unexpected token. How is that possible?

**URL:** <https://forum.ionicframework.com/t/syntaxerror-unexpected-token-how-is-that-possible/48717>\
**Category:** ionic-v3\
**Created:** [April 7, 2016, 5:36pm UTC](https://forum.ionicframework.com/t/syntaxerror-unexpected-token-how-is-that-possible/48717 "2016-04-07T17:36:07Z")\
**Posts on this page:** 1\
**Showing post:** 8

<div class="post-metadata">

**Author:** ![tim](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/tim/32/7550_2.png) [@tim](https://forum.ionicframework.com/u/tim)\
**Post date:** [April 8, 2016, 10:35pm UTC](https://forum.ionicframework.com/t/syntaxerror-unexpected-token-how-is-that-possible/48717/8 "2016-04-08T22:35:35Z")

</div>

Hey all! That is a valid TypeScript type, but it isn’t valid ES6/ES2015 syntax. Angular2 uses that type information in TypeScript projects for doing dependency injection, so in JS projects you need to use the static getter `parameters` to attach that information to the class (so Angular2 knows what thing it should inject).

This didn’t error previously because Ionic starters were using the TypeScript compiler under the hood, but it should have been, as types are not valid syntax in JS.

---

_[View the full topic](https://forum.ionicframework.com/t/syntaxerror-unexpected-token-how-is-that-possible/48717)._
