Skip to content

Instantly share code, notes, and snippets.

@nmerouze
Created December 1, 2009 20:20
Show Gist options
  • Save nmerouze/246604 to your computer and use it in GitHub Desktop.
Save nmerouze/246604 to your computer and use it in GitHub Desktop.
$.getJSON("http://search.twitter.com/search.json?&q=from:nmerouze&callback=?", function(data) {
});
$.getJSON("http://search.twitter.com/search.json?q=from:nmerouze&callback=?", function(data) {
var tweets = _.pluck(data.results, "text");
});
$.getJSON("http://search.twitter.com/search.json?q=from:nmerouze&callback=?", function(data) {
var tweets = _.pluck(data.results, "text");
alert(_.first(tweets)); // or alert(_.last(tweets));
});
$.getJSON("http://search.twitter.com/search.json?q=from:nmerouze&callback=?", function(data) {
var tweets = _(data.results).pluck("text");
alert(_(tweets).first()); // or alert(_(tweets).last());
});
module("Boldr", function(c) { with(c) {
module("Hello", function() {
def("hello", function() {
alert("hello " + this.name);
});
});
constructor("MyClass", function() {
include(Boldr.Hello);
def("initialize", function(name) {
this.name = name;
});
});
}});
var myClass = new Boldr.MyClass("world");
myClass.hello();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment