Live data from Hacker News

Angular 2 Core

docs.google.com

271–279 of 279 posts

Re: Angular 2 Core

#272
1. For developers, change is usually a good thing in regards to our careers. If you aren't learning and growing, it's not Angular that will go away, it's you.

2. They are following the http://semver.org definition of a major version change perfectly fine "MAJOR version when you make incompatible API changes".

3. If anyone is bothered by the complete shift, fork Angular at version 1.3 and maintain it yourself. That's the joy of open source. You might even be a hero to many other developers.

Re: Angular 2 Core

#273

I want to be excited, but at the moment there's just so much new and unknown stuff I'm seeing that I'm just not sure. I don't like the new template syntax; html attributes with parentheses and whatnot just look non-standard and I don't really see why they did all that. I really need to dig into the design documentation and find out the whys behind all of these new features. ES6 is also new, of course; when I first sa…

I disagree. New syntax actually gives much more for compatibility with other technologies and IDE integration. Also clean visual difference between events and properties - big thing. Not valid HTML... Well, not so high price.

That's a fair point. Being able to differentiate complex directives from attributes greatly helps separate the concerns visually.

Re: Angular 2 Core

#274
Great to see HTML5 growing so rapidly during the past few years! That said, I'm not a huge fan of frameworks, they do not work so well except for basic pattern apps. When you have an app worth building you consider very carefully what foundation stones to use. I ended upright on my feet and happily dancing using React as one of the stones.

Re: Angular 2 Core

#275
post #203
post #124

Earlier quoted context omitted.

For example, if an instance of House requires a Door it is not enough to just require('Door'). You still have to do the equivalent of `new Door()` in your House module to get an instance. By doing so within the House module you just tightly coupled House to Door (your House now knows how to create Doors). So what? What is so bad about House and Door being "tightly coupled"? Here's a House constructor that can take an…

I felt the same way about DI until I watched this video: http://www.youtube.com/watch?v=_OGGsf1ZXMs

Fantastic video. I think it nails what DI is good for, and furthermore, what a DI framework is good for. Not only that, but it's a faaaaar more elegant solution than what's been in Angular so far.

Re: Angular 2 Core

#276
post #32

Earlier quoted context omitted.

I remember when I looked into React that I was basically writing HTML templates into javascript code. Are there ways around doing that now with React? Because I find that to be a pretty big affront to separation of concerns

Having used React for a year now, I have long concluded that React doesn't violate any separation of concerns at all. React implements UI views and controllers. You write views that know how to render themselves, and then you write views that control them; the latter type of view fulfills the role of the classical MVC controller. For example, consider how Cocoa works. It's a classical MVC framework: You have a view c…

> Interface Builder is separate, and keeps its view data stored separately, because a WYSIWYG editor can't touch code. (Actually, Delphi showed that it was possible, but that's another story.)

Oooh, do tell!

Re: Angular 2 Core

#277
post #276

Earlier quoted context omitted.

Having used React for a year now, I have long concluded that React doesn't violate any separation of concerns at all. React implements UI views and controllers. You write views that know how to render themselves, and then you write views that control them; the latter type of view fulfills the role of the classical MVC controller. For example, consider how Cocoa works. It's a classical MVC framework: You have a view c…

> Interface Builder is separate, and keeps its view data stored separately, because a WYSIWYG editor can't touch code. (Actually, Delphi showed that it was possible, but that's another story.) Oooh, do tell!

Delphi automatically synchronized itself with your code. They called this "two-way editing" and it was magical, and worked wonderfully.

Let's say you created a form, which in Delphi parlance was a surface that could inhabit controls, typically an actual application window. You would get this empty window:

http://www.vwlowen.co.uk/basicdelphi/images/theide.jpg

You would also automatically get a source file containing the class definition for that form, roughly corresponding to a window controller class in Cococa. This class would be completely empty, mind; no init code needed or anything:

http://136513.jakero00.web.hosting-test.net/wp-content/uploa...

(The GUI layout would live in a separate binary "form file" you never needed to edit directly. This file contained serialized objects that you could read and write in code, similar to OS X bundles, except more easily extensible.)

This class would be, by virtue of having the same base file name, automatically linked up with the corresponding form, so you could quickly switch between code and UI.

Then if you added a button the form, Delphi would automatically add a private member variable declaration "FButton1: TButton" to your class definition, as glimpsed here:

http://www.delphisources.ru/pages/faq/master-delphi-7/conten...

The framework would know, from the GUI definition, that FButton1 was that button. You could edit it and move it around in your code, and it would still be bound correctly.

Same thing with event handlers: If you went into the button's inspector and double-clicked on the "click" handler, it created the method for you, and placed the cursor in the right place so you could immediately fill it out with code.

This system made developers insanely productive, because the "boilerplate interactions" were reduced to almost nothing, and all the work was actual work. No "IBOutlet" stuff needed, no manually connecting the variable to the right thing in the GUI builder, and very little setup.

A few more brilliant, deceptively minor details made this even more magical. First, the form you edited was truly "live". Delphi actually rendered real controls in the editor. If you created a control that did custom rendering, it would render like that in the GUI editor, live. Interface Builder sort of does this, but not quite, and custom controls are a pain and apparently no longer supported.

The second thing was the object inspector:

https://www.ibm.com/developerworks/data/library/techarticle/...

Interface Builder has a very poor one; Delphi's felt natural. Every property exposed by a control would be visible there through reflection: Delphi would actually parse properties out of your code. It supported structured properties, so if something was a TFont, it expanded into sub-properties for font name, font size and so on.

If you created a new class TGradientButton or something, and exposed two properties FromColor and ToColor, they would show up in the object inspector, automatically, and since these properties would be something like TColor, it would know to display an RGB widget for them.

You could also register custom object inspector behaviour, so that, instead of FromColor/ToColor, perhaps there was only one property "Gradient" of type TGradient. Your custom object inspector thingy could then render a gradient editor for that property.

XCode + Interface Builder is about 10% of what Delphi was. I say "was", it still exists, but I haven't touched it since around 2000-2001. It's insane that Delphi 1.0 in 1995 was more powerful than XCode + Interface Builder today.

(I suppose it lives on in the Visual.NET tools; after creating Delphi, Anders Hejlsberg joined Microsoft and created C#. But I haven't used any of it.)

Re: Angular 2 Core

#278
Nothing surprising or disappointing here in my opinion. It was my understanding from day 1 that ng was Google's experiment and attempt in transforming and mutating HTML into a language for web apps instead of web sites.

Re: Angular 2 Core

#279

I tried both EmberJS and Angular. To me it seems Ember is years ahead, the main advantages: - clean model abstraction, which prevents soo much boilerplate - clean templates - components, partials, great re usability

I've built one significant project in Ember, and three in Angular (multi-month projects with a small team; requiring maintenance for the next 3-4 years; Ember 'feels' so much more right to me. I really enjoyed working with it and it reminded me of the desktop frameworks I used to work with. It's not without it's faults, but what is. But sadly Ember just doesn't seem to be holding it's head up in the ongoing swell of…

"its"
Post reply on HN