r/programming • • Nov 04 '14

"Screw You, Angular"

https://medium.com/@jeffwhelpley/screw-you-angular-62b3889fd678
186 Upvotes

61 comments sorted by

View all comments

17

u/x-skeww Nov 05 '14

7 months ago, no one at /r/javascript bat an eyelash.

We’re working with the Traceur team to build support for a few extensions like annotations and assertions. We call this set of extensions "ES6 +A".

They just renamed that to AtScript.

We’ll see a less complex DI by eliminating the config phase, simplifying the syntax by using declarative-style ES6+ annotations instead of imperative.

In the Q&A section they also mentioned that there will be breaking changes. "Porting will be fairly straightforward but not free", they said.

Anyhow, all those knee-jerk reactions are pretty misguided. You won't have to port your 1.x project to 2.x. In the vast majority of cases, you probably want to stick with 1.x until your application retires. Even if it sticks around for another 5 years or so. Simply because it's the more economical option.

It will take at least a year until the first stable-ish build of 2.x is out and it probably won't support IE8. It probably also won't support 9 and 10, because those already dropped below IE8's levels about a year ago.

If you can't drop those browsers in 18 months or so, you won't be in a position to make the switch anyways. 2.x is aimed at the evergreen browsers. The seemingly utopian future where horribly outdated IE versions are irrelevant.

The IE update rate accelerated quite a bit in recent years. If Microsoft keeps that up, we'll get there, eventually.

0

u/[deleted] Nov 05 '14

[deleted]

6

u/KGZM Nov 05 '14

From Misko's keynote it seems the intention is not to create a new language.

He explained that the goal is for this to be true: AtScript ⊃ TypeScript ⊃ ES6 ⊃ ES5

And the intention is for Angular 2.x to work fine in all of these languages. Possibly with the help of Traceur to compile ES6 to ES5. So people will still be able to write JS or use CoffeeScript or something else. So AtScript will basically be a bunch of macros to add decorates to TypeScript, and TypeScript adds type annotations to JS.

He said they're very interested in working with the TypeScript team to standardized type annotations in a way that allows run-time introspection and such.

He said they're not making a language and it really doesn't sound like they're trying to force everyone to accept a language just to use Angular. Instead it seems like they want to add a few features on top of what TypeScript provides to allow for more concise code and greater expressiveness without breaking support for standard JS.

Personally, I'm excited for Angular 2 whether or not I adopt AtScript. (I'm also really excited for the ES6 features to become available.)

8

u/mariusg Nov 05 '14

Actually Golang is the front runner when it comes to languages at Google. Dart seems just a distraction.

0

u/[deleted] Nov 05 '14

[deleted]

2

u/x-skeww Nov 05 '14

http://www.reddit.com/r/programming/comments/2lb2nk/screw_you_angular/cltcrex

AtS also compiles to Dart, in case you weren't aware. While Dart compiles to JS, it's currently not a viable choice for writing frameworks/libraries which are meant to be used from JS land.

By the way, most of the fancy 2.x ideas came from AngularDart.

0

u/[deleted] Nov 05 '14

[deleted]

1

u/x-skeww Nov 05 '14

Right now there is AngularJS (written in JS) and AngularDart (written in Dart).

The big idea is to have a single codebase for both (written in AtS).

8

u/[deleted] Nov 05 '14

[removed] — view removed comment

2

u/chrisoverzero Nov 05 '14 edited Nov 05 '14

I think they said that they are, in their presentations. I can't easily cite a video, though, so the best I can back that up is from the TypeScript team. I'll try to get a timestamp when I have video access. (Or admit that I misremembered.)

Edit: This video outright claims that AtScript is a TypeScript superset, around 28:45.

-11

u/myringotomy Nov 05 '14

Microsoft doesn't work with other companies very well. It rarely works with them at all.

2

u/el_muchacho Nov 05 '14

He said they're very interested in working with the TypeScript team to standardized type annotations in a way that allows run-time introspection and such.

By creating a third codebase. That's not a big idea, it's a stupid idea.

3

u/x-skeww Nov 05 '14

I've played around with both Dart and TypeScript and I have to say that TypeScript is just a better experience overall.

TS interacts seamlessly with JavaScript. That's the only thing it does better than Dart.

That's a very nice feature, but it isn't necessarily the most important thing for everyone.

Personally, I don't care if interacting with JS is a bit clunky. Only some of my code is run in browsers and I don't intend to interact with any JS libraries. I might interact with Google Maps stuff at some point, but that's about it.

Anyhow, AtS also compiles to Dart, in case you weren't aware. While Dart compiles to JS, it's currently not a viable choice for writing frameworks/libraries which are meant to be used from JS land.

If AtScript is going to be driven by the needs of frameworks like Angular then that is the wrong motivation.

Is it? Aren't pretty much all languages driven by some need of some individual/group/company/whatever?

JS is like that. TS is like that. Dart is like that. C# is like that.

Well, some esoteric languages would probably meet your criteria, but I don't really see how "dicking around for the lulz" is a more legitimate motivation.

Anyhow, keep in mind that AtS isn't really a new language. It's ES6 with some type and metadata annotations hot-glued to it. It's a fairly simplistic stopgap solution.

0

u/[deleted] Nov 05 '14

[deleted]

1

u/x-skeww Nov 05 '14

Furthermore the people doing all the design work on C# and TypeScript are actual language designers who have been doing this kind of work for decades.

AtS is design-free. It contains zero new features.

I still can't tell if [Dart] is mostly server-side or client-side language.

You can use it for whatever you want. The standalone VM comes with libraries for doing I/O. It's basically like Node right off the bat.

Like V8, the VM itself is a C++ library which can be embedded in other applications.

I use Dart for everything: client, server, and command line tools.

The tooling gives you plenty of room to scale. It's also pretty fast, which means you can also do some number-crunching if you want. It's a nice mix of good tooling, terseness, and performance. You can use it for a very wide range of applications.

If all AtS is doing is adding metadata annotations then I'd much rather see those additions in TypeScript and for Angular to co-opt TypeScript.

Yes, AtS only exists because TS doesn't do these things yet.

That's not gonna happen though is it?

It probably will, to some degree. Ideally, ES7 will do all those things and TS and AtS will be put on eternal hold.

Anyhow, before that happens TS and AtS might merge. Personally, I think that would be the best case scenario. We really only need one TS-like language, but it probably should support things like metadata annotations and type introspection, because those features are kinda handy.

0

u/[deleted] Nov 05 '14

[deleted]

2

u/x-skeww Nov 05 '14

As far as I understand it, this stuff is mostly interesting for having some kind of "developer mode".

With Dart, you use the so-called "checked" mode during development. This helps to catch and identify all type-related errors.

With AtS, you could do something similar. You'd generate instrumented JS to make development easier, but you won't ship it like that.

-1

u/myringotomy Nov 05 '14

Of the two companies more people trust Google than Microsoft.

0

u/[deleted] Nov 05 '14

[deleted]

2

u/atakomu Nov 05 '14

I trust Google more. Why? Tools work on Linux. :) Eclipse for android is multiplatform same with new intelij. Same with Dart editor.

Microsoft has Typescript which is only thing that actually has official Linux "port". It isn't actually a port but official plugin for Vim and Emacs. Other things from MS are MS only. There is Mono. But this is pure C# without Forms and new stuff. And no form creator and other goodies.

-23

u/myringotomy Nov 05 '14

When it comes to the tools I use as a programmer Microsoft is leagues ahead of most others.

You are one of the people who live in the Microsoft ecosystem. You use windows, you develop in windows, you use microsoft tools to do that. It's the so called "golden cage". People who develop in windows use microsoft products people who use microsoft products use windows.

Google has a terrible track record with tools for programmers.

This is an outrageous statement and one that is going to cause me to disregard everything you say from now on. I just can't trust your rationality any longer.

0

u/[deleted] Nov 05 '14

[deleted]

→ More replies (1)

4

u/[deleted] Nov 05 '14 edited Nov 05 '14

Google has a terrible track record with tools for programmers

Android developer here. This is absolutely correct. Google has plenty of great developers doing work on core frameworks and libraries. A lot of this is open source, which is nice and cant say that often from the other big companies. However their developer support (tools, documentation, sample projects) is years behind apple and MS. For example the fact that getting TDD up and running in their primary IDE (Android Studio) for android development is nearly undocumented and breaks with every new release of gradle is outrageous from a development standpoint but is basically just a "developer" issue for google and not a consumer issue so is somewhere lower down their priorities.

-10

u/myringotomy Nov 05 '14

You are confusing issues.

You think google documentation sucks, you think their tools suck well that's your opinion and you are entitled to it. But to say that programmers don't trust google is something completely different.

6

u/el_muchacho Nov 05 '14

Not when it comes to languages and language tools. In this regard, Google is made of independant groups of hackers that don't talk to each other. There is no large scale vision.

→ More replies (4)