Recent submissions

Comment · 12 years ago
What's the rationale for doing this, rather than simply using the package from upstream?
Comment · 12 years ago
That would be perfect for a ratio-enforcement scheme that works cross-tracker.

I'm sure there would be ways to game it, but it could go a long way in ensuring the average user gives what they get. It would be awesome to integrate a 'currency' into a similar client, where you slowly earn more by seeding.

Comment · 12 years ago
Comment · 12 years ago
That's nonsense. There are a lot of reasons that a first (or any) job isn't a fit, and a whole lot of them aren't caused by the employee's negative traits.

Just to name a few: the job description didn't match the actual job, overbearing managers, overbearing coworkers, uninteresting work, a better offer elsewhere, changing interests, or - just like OP - the employee feels like he would grow his talents better elsewhere. I have been in the same situation and employers have understood and respected my decision.

Comment · 12 years ago
Comment · 12 years ago
Lots of people do - some backup providers charge tiered amounts or 'unlimited' data, and the convenience of getting your OS back exactly the way it was is absolutely worth using an extra 10-20GB of storage.
Comment · 13 years ago
A chrome extension can make network connections that you won't (normally) see in Dev Tools using a background page. You'll see the connections if you inspect the background page directly but most users won't.

Unfortunately this is simply a byproduct of the web's (and browsers') botched security model; there is no way to allow extensions to modify pages without them being able to read the pages, and if they can read the pages they naturally can catch events, including keystrokes.

This is why you should think - hard - whenever allowing any extension with that permission. It could autoupdate at any time to include malware.

There are a lot of bad extensions out there. I've encountered quite a few. It's a wide-open vector for exploitation and it happens all the time. Just last month I came across a game extension (super mario clone) that contained jQuery. Upon further inspection, it turned out it had been re-minified (making diffs difficult) and had a few lines deep inside that hijacked ads and replaced them with the author's ad network. Silent, effective, and this extension was on the 'top lists' for months. It might even still be there.

Be very aware of the permissions an extension asks for.

Comment · 13 years ago
This is a fantastic feature, and something that preprocessors like SASS/LESS cannot do without complicated workarounds.

There are often times in my CSS workflow where I want to do something similar to this:

  .widget
    $padding: 3px
    $activeColor: $color1
    $inactiveColor: $color2

    padding: $padding
    /* ... etc. */

  .subWidget
    $padding: 6px

  .subWidget2
    $inactiveColor: $color3
    /* ... and so on */
With preprocessors, this doesn't work - you're better off defining a mixin that you feed variables into, which isn't the most intuitive approach. I hope this is adopted quickly by the major browser vendors. Unfortunately, writing your styles in this way will completely break in browsers that don't support it, in the absence of some sort of polyfilling JS or build tool.
Comment · 13 years ago
That's not the first time I've been disappointed in the style and operation of the JS packaged with bootstrap. While they solved some useful problems and packaged it nicely, they did so with very little regard for style, performance, or extensibility.

The typeahead plugins, both the bootstrap and the larger standalone versions, are hellish to work with or modify in any way. The same goes for dropdown and many others. Unfortunately they never thought that anyone would use these plugins except in their prescribed way - so few to no events are ever thrown, and incoming events are often canceled (stopPropagation, preventDefault), making it hard/impossible to reuse those events for other interactions.

I have had to monkey patch bootstrap JS more times than I can count and I generally stay away from it now. I don't think there's anybody paying much attention to the repos anymore; the number of issues and PRs outstanding for typeahead.js (a small library!) is pretty astounding.

FYI, the older versions of bootstrap.typeahead were more performant, but of course did far less than the now standalone typeahead.js does.

Don't get me wrong, typeahead.js is a nice project and the devs have clearly worked very hard on it. It does some really nice things. But there is clearly some leakage from the twitter style where comments are barebones, assignments take place in conditionals, semicolons are missing, and ~ is a common sight. It is effectively write-only code.

Comment · 13 years ago
That's really interesting! Could you post any examples of how you're using it?
Comment · 13 years ago
TFA is arguing to use the router for navigation without having it push a separate URL to the bar, and still have back/forward work correctly. Essentially, creating a route change that isn't a route change, so it can properly trigger a router action. Of course, this is the actual point of `stateObject` as far as I understand it.

I think this is a good idea and would make a nice simple Backbone plugin. I've run into similar issues before; sometimes you want to display a temporary menu or other interstitial without a refresh taking you back to it.

Some purists get annoyed by this sort of thinking; they think that the URL bar should always reflect the current state of the app. I disagree with that line of thinking; different apps have different requirements and one size definitely does not fit all.

I've been writing Backbone applications for a while and I constantly run into router limitations that require creative solutions to get around. Backbone.routefilter is a great way to get some more flexibility - in every project I usually use a home-rolled combination of routefilter and a few more injected events. One of my favorites is to add permissions checking at the router definition level, to provide routes that only specific users should be able to use.

I've also been floating the idea around in my head of the url being essentially just a text representation of a state object - could easily just be a query string or something similar. Instead of a router globbing the url, you could attach event listeners to events on specific properties (similar to model/collection events), giving you all the power that most server-side routers have. For example:

    var MyRouter = Backbone.ExtendedRouter.extend({
      routeEvents: {
        'var1' : {'change' : onChange},
        'var2' : {'change add remove' : onVar2Event},
        '' : {'all': onRoute}
      },
      // ...
    });
And so on.

It would then be great to use the above microstates idea to create a navigation api like the following:

    App.Router.setState(publicState, privateState, triggerOptions)  
    App.Router.replaceState(publicState, privateState, triggerOptions)  
    App.Router.addState(publicState, privateState, triggerOptions)  
That way, we can trigger routes exactly when we want them (with or without an actual url change), store private state using the History API, and support microstates. The best part (IMO) is that different routers can listen to separate parts of the url, allowing a URL change to trigger multiple routes on completely separate routers. This would go a long way toward true separation of concerns in larger apps.

Of course a lot more needs to be fleshed out. If any BB devs are interested in helping with idea, please let me know (email in profile)!

Comment · 13 years ago
I think the GP was on the right track, but somewhat confused. They obviously don't do this on all models, but some dual-core models are disabled quad-cores. Remember the Athlon X3? That was a binned chip that usually was created from X4s with a broken core. Most buyers didn't mind, and some of them got lucky and were able to re-enable the disabled core.

It seems like the GP might be suggesting that a quad-core CPU will swap in another core when one dies. That doesn't happen. But the binning process allows them to still sell slightly defective silicon with disabled parts (cores, cache), which saves money.

On a related note, a lot of GPUs actually do have a few dozen execution units that are disabled by default and can be swapped in after stress testing at the factory. I believe some can even do that in the wild, but I could be wrong.

Comment · 13 years ago
Just use coinbase. IMO it's the only exchange that actually does fiat currency to BTC correctly - all the rest have horror stories posted all over bitcointalk and reddit.
Comment · 13 years ago
You have to admit, that responding to a very informative message comparing and contracting Solaris's networking stack with Linux's with

  Have you ever kissed a girl?
  - Bryan
is incredibly tasteless.

But of course that was long ago.

I don't think it at all appropriate to criticize what was clearly an honest mistake with a call for his employer to fire him. I would expect that of the masses on Twitter and commenting on the PR, but not of Joyent or Cantrill.

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton