Labs/Ubiquity/Ubiquity Source Tip Author Tutorial: Difference between revisions

Jump to navigation Jump to search
Line 359: Line 359:
CmdUtils.CreateCommand({
CmdUtils.CreateCommand({
   name: "tinyurl",
   name: "tinyurl",
   takes: {"url to shorten": noun_arb_text},
   takes: {"url to shorten": noun_type_url},
   preview: "Replaces the selected URL with a TinyUrl.",
   preview: "Replaces the selected URL with a TinyUrl.",
   execute: function( urlToShorten ) {
   execute: function( urlToShorten ) {
Line 370: Line 370:
})
})
</pre>
</pre>
Although I used the <code>noun_arb_text</code> command noun-type, I should have used the <code>noun_type_url</code>&mdash;if such a thing existed. It doesn't yet.


jQuery is a powerful tool. With it, you can fairly effortlessly cherry-pick the data you need from RSS feeds, XML, and all sorts of other data formats. It also makes doing in-preview animations a breeze.
jQuery is a powerful tool. With it, you can fairly effortlessly cherry-pick the data you need from RSS feeds, XML, and all sorts of other data formats. It also makes doing in-preview animations a breeze.
1,007

edits

Navigation menu