News for hackers. Stuff that matters.

qqqq2010

Re:Introduction to Object-Oriented JavaScript - MDC Docs on Wednesday May 04, 2011 @12:57PM (#2514427)
It's ensuring a default value basically. If you instantiate a person without an argument and try to reference this.gender later, you'll throw a script error. This is just avoiding that.

A way I'd prefer might look like this:

  function Person = function(gender) {
      this.gender = gender || 'neuter' //the sauce that defines a fallback
  }
Maybe inspecting source is their first bar to get over? Pretty low if so...
Oh man... the Rhino is a good reference, but lacks all kinds of best practices and essential style pieces.

Between 'proper' OO style, short circuiting on falsey assignment (var a = b || "default"), checking existence to avoid errors ( if (myObject && myObject.getJSON()){//block to deal with JSON} ) and the DOM, I feel like this is only useful to look up the Date() and Math() methods.

Sorry, just griping because it was the first 'real' programming book I got, and I feel that it misled me for quite a while. </rant>

Re:New MacBook Pro series on Thursday February 24, 2011 @12:26PM (#2258838)
So I (blindly) thought that an Apple-integrated SSD might somehow be better than an aftermarket add in I drop in, RE TRIM. Is this not the case?

IANAHDS (I am not a hard drive specialist)

Re:Can you use PHP without frameworks nowadays? on Friday February 18, 2011 @01:47PM (#2236664)
You know, I was nodding my head as I read the OPs progression. The first programming I ever tried was Rails (it's the hotness, why not dive in!). My problem was that it was magically solving problems I didn't know I had.

I would strongly argue for (if you have time) experiencing the progression of web dev to its current state from the ground up. Understand WHY templating is useful. Understand that most basic CRUD controllers have the same methods, and the schema underneath is setup the same way. Doing some things the 'hard' way I found made it much easier to understand the reasoning behind today's most modern frameworks. I understood their benefits.

Re:Developing When Your Computer is too Fast on Saturday November 13, 2010 @12:04AM (#1900342)
Incidentally, as a webdev who targets big businesses, they in fact usually have -slow- computers. Javascript in IE 6 is pokey, and typical use-cases of Outlook and Excel don't need much firepower.

A joe-blow at home on the other hand is either at least at the "corporate" level, or even higher for gaming or media-centering.

Re:Ask HN: Show me your Half Baked project on Friday October 22, 2010 @10:53PM (#1822419)
A service that has no backend (no server calls, DB, 'scary' stuff to consumers) that lets you back up your tweets on your own terms. Basically gives you ownership of things you write, without relying on any third party to access, store, or send you your own writing. Eventually will be given out as a folder with some .js and .html files, all self contained.

http://www.mcphersonindustries.com/bucket/tweets/RunMe.html

Re:Confessions of a Used-Book Salesman on Wednesday October 06, 2010 @09:57PM (#1766571)
The Lorem Ipsum book store in Cambridge, MA does just this. It was started by some MIT kids (afaik) with some basic algorithms set up to judge the "goodness" of a book when they go to sales or get turn-ins from customers for store credit. They don't solely include the Amazon sale price of a book though, somehow they definitely include unique-ness or coolness: their store is stuffed to the gills with amazingly interesting books on all topics (all of which are cross listed on Amazon also).

Seems to work for them. How many other independent bookstores have gone under lately? When I moved out of Cambridge last year, Lorem Ipsum was just upgrading to a new, larger facility.

http://www.loremipsumbooks.com/

Typo: I think you probably meant garlic 'cloves' not garlic 'gloves' in the onscreen recipe. Minor, but I noticed.

Ask HN: Unique Developer Blogs?

I love a very specific kind of blog/article/post and I'd love to know if more exist. They post 'lessons-learned' and 'process-insight' articles about their large scale development efforts.Specifically: These are not "how-to" copy/paste script sites, they don't offer a downloadable library at the end, and they are run by legitimate, innovative, startup-like companies. The ideal posts are higher...

( Read More... | no comments | 3 points | on HN )
At the beginning of the learning curve, there's little better for grasping topics than hearing someone else explain them. I've learned more (almost entirely by virtue of genius co-workers) in the first 6 months of my current, first, developer job than I did in ~2 years of self learning and freelancing.
Re:Ask HN: Who's Hiring? on Friday April 30, 2010 @01:15PM (#1308748)
Wall Street on Demand, Boulder, CO. Need to work onsite.

http://www.wallst.com