HNHacker News
TopNewBestAskShowJobs

nxn

238 karma · joined June 30, 2010

submissionscomments
nxn··on Ask HN: What DON'T you like about your Macbook?
MMMOOOOOOOOOOO
nxn··on Ask HN: What DON'T you like about your Macbook?
Well, before my macbook was stolen:

- Optical drive was unusable if you had the macbook in your lap; slight movements would cause the disc to scrape against something in the drive. Somehow when I mention this to mac owners they get into a rant about how it's unreasonable to complain about this. Forgive me for trying to use a laptop in my lap.

- Loud mooing fan and other noises that were hard to identify.

- The magnetic latch put so much pressure on the cheap plastic that it would crack it.

- The cheap plastic would get discolored after a while of use.

- Trackpad was horribly inaccurate causing the cursor to noticeably jump if you had your finger over a certain portion of it.

I'm sure I'm forgetting some other hardware issues, the whole thing just felt incredibly cheap for the price. Biggest annoyance actually came from the mac communities and how defensive they got when someone would mention these problems.

nxn··on Do you have what it takes to build a great site? (Flowchart)
Ehh, I used to work with ASP.NET at work, moved to ASP.NET MVC, and now I switched jobs and got stuck with the classic ASP.NET flavor again. As much as it pains me to admit it, it does feel "aged" and "legacy" to me these days.
nxn··on Why Microsoft has made developers horrified about coding for Windows 8
The video the article links to has Julie Larson-Green going over the tiled interface. Different video from the one you are referring to I believe, but it covers almost the same exact material in a very similar manner.

Here's the link used in the article: http://allthingsd.com/20110601/microsofts-windows-8-demo-fro...

nxn··on Why Microsoft has made developers horrified about coding for Windows 8
"But one aspect of the demonstration has the legions of Windows developers deeply concerned, and with good reason: they were told that all their experience, all their knowledge, and every program they have written in the past would be useless on Windows 8."

I stopped reading there. It's amazing that spreading unfounded trash like this can be called news. All this is is an attempt to twist and stretch the truth in hopes of provoking a reaction and attention -- simply pathetic.

nxn··on Ask HN: Could you build an entire web app in just one language?
There are JavaScript UI libs that handle the HTML/CSS for you like ExtJS. You'd still need to at least supply a single HTML file that just loads the js files though, but that hardly requires knowing HTML/CSS. After that the whole presentation layer is pretty much defined with JS and JSON.

That's in theory though -- in practice I wouldn't expect to get very far before not knowing html and css became a significant hurdle while developing a web app.

Anyway, these days I wouldn't even suggest building web apps as a starting point for someone's programming related career; it's just too big of a mess of languages, frameworks, and libraries. I think just about any academic curriculum aimed at application development starts off with basic console applications, works up to GUI apps, and then goes to the web. By then hopefully you see some patterns emerge that make learning new tech easier on you.

Then again, ironically, I did start to learn programming via the web through PHP, so I guess it can be done. The thing that helped me was that I already had a few years of experience working with static HTML, and I understood the problems PHP was trying to solve and felt the need for a solution myself. This was in the late 90s or early 2000s though, things were still a lot simpler back then than they are now. Websites didn't absolutely depend on JavaScript, you didn't have to know anything about AJAX, seeing CSS was fancy since having style information in your html was still common.

I don't know, if I think about learning all of it at once from scratch these days I want to vomit and have a seizure. So yeah, to answer the OPs question, I guess I do see how the benefits of unifying and abstracting a lot of the pieces out might be useful.

nxn··on Microsoft’s Silence is Infuriating .NET Developers
To clarify:

HTML5+JS is only suitable as a replacement to the presentation portions of .NET (so WPF or WinForms), which are just a small portion of everything that .NET is. Think of .NET as being a Humvee and HTML5 and JS as a motorcycle, and developing your application as going to some remote location in Alaska -- while the motorcycle will look great, it will only get you so far, and you need something more for the rest of the road that can also carry a motorcycle if need be.

JS is a language that primarily lives in the browser and doesn't come with anything that would allow you to access much of the computer it is running on. We're talking about applications that will be executing natively here, so things like access to the file system are a must. You can of course try to use something that implements the CommonJS spec, like NodeJS, but are you honestly going to throw out the massive amount of libraries Microsoft created for doing IO, database connectivity, concurrency, networking, and a whole lot more, for something as minimalistic as an implementation of the CommonJS spec?

There are other problems on top of this. People say JavaScript is "fast", and it's true when compared to JavaScript a few years ago, but it is not true when compared to most .NET languages. Objects essentially being associative arrays in JavaScript means accessing a value that is deeply nested in a hierarchy of objects is slow. While even a problem now, it would get much much worse if you were to throw in the large number of libraries needed to make HTML5 and JS into a general application development framework. Stuff like: Com.Company.Project.Class.Member.Member.Method(); simply takes too much time in JavaScript. Same story for deep inheritance chains you often see in desktop apps.

Another problem: If your whole application is going to be in HTML5+JS, your whole application's source code is going to be public. You can try obfuscation, but I personally wouldn't put much faith into that approach.

.NET was built from the ground up as a whole application development framework -- it does this well. While HTML5+JS overlap with .NET in some areas, their scopes are still much smaller in comparison, and are therefore not suitable as complete replacements to .NET.

nxn··on Few things in Javascript annoy me quite as much as the damn comma...

  [ "Why not just use"
  , "this indentation style"
  , "to avoid the problem"
  , "in the first place?"
  ]
nxn··on Microsoft’s Silence is Infuriating .NET Developers
"Also seeing WebGL taking hold, I must say that I'd certainly consider JS as a serious contender for the likes of .Net etc"

At most I would say JavaScript can be a "serious contender" to a very small subset of .NET. There is no way you can just substitute everything .NET offers with a mix of html5 and JavaScript. That's why I don't think anyone doing .NET development should be in the least bit concerned. That is unless they have some irrational phobia of having to learn something new for their presentation layer.

nxn··on How you clear your HTML5 Canvas matters
Ehh, last time I messed with canvas (sometime around February this year) any approach to clearing the entire canvas was too slow. In order to get any decent performance I had to layer multiple canvases on top of each other and keep the dimensions of the last draw operation saved so I'd only have to clear that bit of the canvas. The layering was so that I wouldn't have to bother redrawing things like the background after clearing something on top of it.
nxn··on How a Dev From China won $9000 in Microsoft's HTML5 Contest
Good lord that is slow. Either an update screwed my browser up or this person needs to change their approach or optimize something.
nxn··on JSHC: a haskell compiler/interpreter written entirely in javascript
yhc, uhc, hjs, ghcjs,"haskellinjavascript", jshc, haskell -> llvm -> emscripten, etc, etc

In fact I wanted to start my own -- except I don't have a single clue of how to even go about doing something like that. Though now that I think about it, I wish all the effort was put into a single project that wouldn't die off within a few months of going public.

nxn··on The secrets of Node's success
I think it was a combination of things. One, the timing was nice because JavaScript was getting more and more attention as its engines were starting to seriously compete for speed. Two, I think the fact that it was JavaScript on the server really helped get it a lot of buzz as it was somewhat "controversial". "Controversial" because I can't think of another language whose users are so split between liking and hating it. Having it invade the server meant a lot of people's blood began to boil as they thought of having to potentially deal with it outside the browser, and a lot of other people who were excited about being able to use it outside the browser. Either way, the combination of love and hate gathered a lot of talk and attention in my opinion.

Now to contrast this with python: I personally have never heard of Twisted before all the talk of Node came about. Mind you, I'm not a python developer and if someone's blog title doesn't grab my attention by having some connection to me, or what I do, I'll probably just skip over it.

nxn··on Mozilla's Webian Shell interface will cloak your OS in a browser (video)
Well, a whole web based OS I understand, and maybe I even get using html5/js to do a few things in an OS interface -- though I'd personally not go that route myself. This though is completely confusing to me. Perhaps the article and video provide a poor explanation, but it seems like I can already achieve the main advantages of this experiment by just pressing F11?

I get Chrome OS because it's different and gives a certain set of people what might actually be of some use to them (ie, all data online, you're always in sync, etc). I get enhancing desktop UIs with the things that worked well on the web -- but to start throwing out almost everything that evolved on the desktop just to get a webby feel? Not sure what problem that tries to solve.

The most interesting thing though is that after years of hearing that the future of the desktop will be web based, the idea finally seems to have picked up.

nxn··on HTML5-based Windows 8 enrages .Net devs, alienates Linux and Mono
ExtJS's set of grid panels was just about the most impressive one I've seen thus far (tree grids, group grids, paging grids, features for filtering/searching, sorting, hide/show columns, binding to xml/json/direct, etc). Though it would probably huge overkill to tie yourself into the whole framework just for one widget.

Examples: http://www.sencha.com/products/extjs/examples/#sample-2

nxn··on HTML5-based Windows 8 enrages .Net devs, alienates Linux and Mono
C#: var obj = new { propA = 1 , propB = "meh" };

JavaScript: var obj = { propA: 1 , propB: "meh" };

I admit that's about as close as they get syntactically, but with type inference, higher order functions, and anonymous types they really kind of "feel" similar in some cases. Oh, and C# has optional dynamic typing, so it can ~really~ feel similar if you want.

nxn··on HTML5-based Windows 8 enrages .Net devs, alienates Linux and Mono
I'm not going to say I disagree with you, I'm just quite stumped as to why such a large portion of web developers don't like static typing. These days a static language with good type inference honestly gets rid of most of the burden and the ugly verbosity while still giving you compile time checking.
nxn··on HTML5-based Windows 8 enrages .Net devs, alienates Linux and Mono
Well, this part: "If you are a Windows developer, I'll bet you did: there was little to no mention of .NET technology in the Windows 8 hoopla, and quite a few Windows developers are more than a little angry about the whole thing."

The "more than a little angry" part links to: http://forums.silverlight.net/forums/p/230502/562113.aspx where you actually do see some .NET people raving like lunatics. So I guess I was kind of writing about that in my post.

nxn··on HTML5-based Windows 8 enrages .Net devs, alienates Linux and Mono
"The only people who can make that claim are those who don't really know what .NET is."

Since this is about .NET developers supposedly being enraged, I'd guess it's more likely they don't know what HTML5 or JavaScript is -- and perhaps this leads them to assume it's somehow possible to use them as a "complete" application development platform. I don't know, either way I can't believe people are so lacking of reasoning to actually be concerned about this.

I mean even if their worst nightmares came true and this was a sign that .NET is going to get phased out, Jesus Christ, just learn another platform. Carry the .NET experience over to something else, stop cornering your career into a single technology with some delusional idea that it will never become obsolete, and for god's sake stop crying like babies.

nxn··on Show HN: Google Charts done in Canvas, side project
I think you meant to say PNG?

My original post though:

"SVG has worked in every IE version since 5."

My experience here, and wikipedia, say otherwise:

"The use of SVG on the web is still limited by the lack of support in older versions of Internet Explorer (IE) which (as of December 2010) is the most widely-used browser. The most widely deployed version of IE (version 8) does not support SVG.[46][47] However, IE9 (released March 14, 2011) does support the basic SVG feature set.[48]"

and:

"Internet Explorer, up to and including IE8, was the only major browser not to provide native SVG support. Native support became partially available in IE9 (the current version of IE, as of March 2011),[48] including embedding SVG-file into HTML using “object” tag as well as “img” tag. IE8 and older require a plug-in to render SVG content."

From: http://en.wikipedia.org/wiki/Scalable_Vector_Graphics#Suppor...

nxn··on Windows 8: HTML5 and AJAX/JavaScript == Modern UIs
What is it with people trying jQuery and immediately jumping the gun into "I can solve all of the world's problems with this!" land? Sure, it's great for DOM interaction, but that's simply not enough for any decent UI framework. The jQueryUI project has what, like 10 widgets despite being around for years? Wooooweeee, you can sure base an OS UI off of that! And I don't care how many jQuery plugins I can find on Google; trying to fit them in together in some cohesive manner is a joke compared to an actual full featured UI framework that uses a MVC or MVVM structure.
nxn··on JavaScript Mixins for grown-ups
This post inspired me to try and create the mixin pattern in C# with interfaces, extension methods, and optional generics. Probably been done before, but meh, here's the result: http://pastebin.com/ZiddNDSi
nxn··on Announcing SproutCore 2.0 Developer Preview
I've used ExtJS with ASP.NET MVC for a few years, and it was quite nice. Just have the controller functions return JSON serialized data instead of a regular view. If decoupling the UI from the server side portion of the app isn't a concern you can also use Ext.Direct, which will allow you to call your server side controller methods from JavaScript by just doing:

ControllerName.FunctionName(arg0, arg1, callbackFn);

nxn··on IOS RAGE rendered with WebGL
Because in the video he specifically mentions getting 50-60 FPS when running it without any screen capturing software and at a resolution similar to apple's retina display. RAGE is also supposed to run at 60FPS on the iphone from what I read about it.
nxn··on IOS RAGE rendered with WebGL
On one hand, it's really impressive to see something like this running in a browser after having years and years of flash games as the pinnacle of browser gaming. On the other, it seems somewhat sad to me that it has about the same performance as a modern cellphone when there is so much more power hiding under the browser. Perhaps off topic, but this really makes me think that there is need for things like Native Client, despite a lot of people openly saying they wish the project would just die since it is not what the web "needs".
nxn··on You Don't Know JavaScript
"This 'irritating problem' of people claiming that they know _____ when they actually don't, is best solved with... drum roll... Source code. Don't tell me you know _____, show me what you did with _____. Today that problem can be solved with Github, Sourceforge, Google Code or whatever."

That isn't really a complete solution to the problem, take my situation as an example: I've been working as a C# dev for some years now, but since the company I worked for ended up owning all the code, and since almost all the applications I helped create for them are internal, I have nothing to really show for it. Why don't I have any side projects I've done with C#? It's just simply not my first choice of language for personal projects due to the fact I have to use it so much on a daily basis; instead, I tend to go with lesser known languages that I'm certainly not as familiar with just because it makes writing some of the code a little more exciting. In essence, I'm claiming to know the language, but the only proof I can give is saying "Well, I used it daily for X amount of time".

nxn··on House tells FCC to drop net neutrality
As far as slowing down progress, there is a danger of this happening without net neutrality as well.

Consider the current state in Australia: you have ISPs that charge you based on GB of bandwidth used per month. For example, lets say your ISP signs a deal with Hulu so that traffic from them is free for you. Most people would probably not give any consideration to competing services because they will have to pay for bandwidth while using them. This is a huge advantage to already established online tv services that have resources to make these kinds of offers with ISPs. Meanwhile, new services that can't afford them get ignored by users despite perhaps having better feature sets.

nxn··on What programming languages do people hate most?
I have distastes towards some languages I've had limited exposure to. Pretty much, these are languages I had to use, but not languages I had to get good at using. Among these would be PHP, VB, and maybe Java (though I actually liked it before I started using C#).

Then, there is JavaScript, which I cannot avoid using despite having concerns with it. I would not say I "hate" it though, it's more of a "love and hate" relationship that formed over time here. I guess I look at it as being in a large city: if you know where to go it can be a wonderful time, if you don't you'll be shot in the face.

Among the things that bother me the most are function only scope, specifically when it mixes with declaration hoisting and implied globals. You can really end up writing some deceitful, innocent looking code that just does not do anything you'd expect it to. It's somewhat simple to avoid any problems that might come up if you're aware of them, but it's made me extra touchy; I get uneasy feelings when I see a variable declaration that is anywhere except the top of the function it is declared in. At the same time, having a large distance between the declaration of the variable and its use has been somewhat problematic for me: if I change the name of the variable, I must also remember to scroll up to change where it was declared, otherwise I just added a new global property. This bites.

The other significant issue I have is inheritance. I wouldn't mind if it actually resembled normal prototype based inheritance, but it just doesn't. It's too mixed up with the classical approach, making the end result neither simple nor powerful. It's easy to see that this problem in the language since there are so many different patterns of creating and extending objects as a result. Almost every framework/lib uses a different approach and tries to abstract it so the end user doesn't have to be aware of it. Of course, that only gets you so far before you end up having to look at how the libs you're using implemented it, and that sort of defeats the reason for the abstraction in my opinion. Something as fundamental as this shouldn't be so problematic, but it is.

Strangely, when I'm looking at EcmaScript 5 and Harmony, and see the changes that might try and fix these things, I kind of feel sad because it just wont be the same JavaScript I got used to fighting with.

nxn··on OCanvas – an object-based canvas drawing library
Well, Internet Explorer's canvas implementation only begins with IE9. I would not expect a lib that is based on canvas to work in any previous version of that browser.

EDIT: And even then, you only get the 2d context, can't do any WebGL fancystuff with any IE. (Though I don't think oCanvas does any of that anyway?).

nxn··on Developing and Deploying ASP.NET MVC Applications On Ubuntu with Mono & nginx
I'm not sure if I'd call that the "#1 desired use case for Mono"; I don't even think such a thing really exists. I mean, I used to develop Asp.NET MVC apps with mono as the target platform, and my setup was fairly different from the one described in this article.

It pretty much boils down to how much customizing you want and the particular components you select to implement your application. The more customization you'll require the more setup work you'll have to get it. That goes for any platform and any mix of tools you pick, not just mono. With that said, if you just want a basic setup, you can get one just as easily as any of the competing platforms.

← PreviousPage 6 of 7Next →