top | item 13160670

(no title)

adamduren | 9 years ago

I found Polymer to be very easy to pickup coming from Angular 1 & 2. The only friction I experienced was difficulty integrating TypeScript.

Given how Polymer components are typically written with the JavaScript included with the HTML file of the component this was not really an easy option for a beginner.

However using tools like polymer-build with gulp you can still get TypeScript support. In the upcoming Polymer 2.0 release TypeScript typings are going to be included with the library!

discuss

order

spankalee|9 years ago

Yep, we're going to greatly expand our support of TypeScript with Polymer 2.0. We'll have supported type declarations, and decorators to help write elements, and eventually (though maybe not at Polymer 2.0's release) tools support in the Polymer Analyzer and IDE plugins. You'll even be able to type check and auto-complete in your templates.

There's a little dated PR that adds TypeScript decorators here: https://github.com/Polymer/polymer/pull/3954 We're probably going to break out the decorators into a separate packages, since the ECMAScript decorators proposal has diverged a bit from what TypeScript supports now.

zacharytamas|9 years ago

Yeah... I used it initially with no TS experience, but coming back to it later I do find myself missing TS. But yeah you can use polymer-build to split the script block out of the HTML file, run it through TSC, then insert it back into the file as JS.