es6 type hinting?

817 views
Skip to first unread message

Tony pee

unread,
Apr 23, 2014, 12:59:42 AM4/23/14
to ang...@googlegroups.com
this is a little OT but how is there type hinting in some of the angular 2 code? eg:


i didnt think this was a feature of es6? does it get compile time type checking?

cheers

--
Tony Polinelli

KamBha

unread,
Apr 23, 2014, 4:43:51 AM4/23/14
to ang...@googlegroups.com
I don't know how if it will make it in es 6, but es.next does have a proposal that matches that syntax:
http://wiki.ecmascript.org/doku.php?id=strawman:guards

I have not seen anything about how one defines a guard. I assume it is whatever matches the instanceof for that class.

The real question is will there ever be a version of JS with annotations? I don't see any proposal on the ecmascript wiki about annotations (which is a little surprising as annotations would solve a lot of problems in angular and other applications).

Kamal.

Message has been deleted
Message has been deleted

Tony pee

unread,
Apr 23, 2014, 2:14:15 PM4/23/14
to ang...@googlegroups.com
So currently is this a feature of traceur? cant seem to find how this code works 


--
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.



--
Tony Polinelli

Tony pee

unread,
Apr 25, 2014, 4:21:17 AM4/25/14
to ang...@googlegroups.com
this mailing list is bawwls. everytime i post.. crickets.. 
--
Tony Polinelli

Mark Volkmann

unread,
Apr 25, 2014, 6:52:11 AM4/25/14
to ang...@googlegroups.com
I don't believe Traceur supports that.

You'd have better luck getting a response to ES6/Traceur questions here: es-di...@mozilla.org.
R. Mark Volkmann
Object Computing, Inc.

Tony pee

unread,
Oct 30, 2014, 4:13:16 AM10/30/14
to ang...@googlegroups.com
looks like this is finally answered with the release of information about atScript ;P
Reply all
Reply to author
Forward
0 new messages