[angular2] Failed to run typescript-version example

46 views
Skip to first unread message

Fielding

unread,
Apr 30, 2015, 11:19:20 AM4/30/15
to ang...@googlegroups.com

There is a typescript-version example on the angular2 website. It is working fine in Plunker, but i failed to run it on my local machine. 

example link: (typescript version)


On my localhost machine, i got below errors. And it seems typescript "main.es6.js" is not compiled into "main.js“, but i have no idea what's the difference between plunker and my machine. 



Pawel Kozlowski

unread,
Apr 30, 2015, 11:24:27 AM4/30/15
to ang...@googlegroups.com
Hi!

First of all, the code is written in AtScript, not TypeScript. Then you must know that Plunker is able to do AtScript -> ES5 transpilation using traceur.
So the difference is that if you want to run ng2 code on your machine you need to transpile  AtScript -> ES5 code.

If you are not sure how to do it / configure the entire setup, you can use one of the starter kits, ex.: https://github.com/pkozlowski-opensource/ng2-play

Cheers,
Pawel

--
You received this message because you are subscribed to the Google Groups "AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email to angular+u...@googlegroups.com.
To post to this group, send email to ang...@googlegroups.com.
Visit this group at http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.



--
AngularJS book: http://www.packtpub.com/angularjs-web-application-development/book
Looking for bootstrap-based widget library for AngularJS? http://angular-ui.github.com/bootstrap/

Fielding

unread,
May 2, 2015, 8:15:04 AM5/2/15
to ang...@googlegroups.com
Thanks, pawel. Your github repo helps me a lot. 
Reply all
Reply to author
Forward
0 new messages