Skip to content

Instantly share code, notes, and snippets.

@jonathanKingston
jonathanKingston / routerissue2
Created April 22, 2012 00:03
sample route issue
BrittoRouter = Backbone.Router.extend({
routes: {
":slug": "findPost",
":slug/": "findPost"
},
findPost: function(slug) {
console.log(Posts.find());
console.log(Posts.findOne());
post = Posts.findOne({slug: 'out'});
Session.set('new_slug', slug);
BrittoRouter = Backbone.Router.extend({
routes: {
":slug/": "findPost",
},
findPost: function(slug) {
alert(slug);
}
});
Router = BrittoRouter();
@jonathanKingston
jonathanKingston / gist:7d855d1657fe260b1358
Last active August 29, 2015 14:26
Brainstorming web safety slogans
Spare me from spies
Don't wreak the web
The war on error
Plug your leaks
infosec has a posse
paranoia is perfection

SimpleDB - Like Indexed DB, but Simple

A simple asynchronous data store.

STATUS: This is a thought experiment, not a serious proposal. Would basic async storage like this be useful? With this plus some locking primitive, could you build Indexed DB?

Like Indexed DB:

  • rich value types - store anything you can structured clone
  • rich key types - Number, String, Date, Array (of other key types)