<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/css" href="/stylesheets/rss.css"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/">
  <channel>
    <title>David's Computer Stuff Journal: Tag javascript</title>
    <link>http://journal.dedasys.com/articles/tag/javascript</link>
    <language>en-us</language>
    <ttl>40</ttl>
    <description></description>
    <item>
      <title>YUI Compressor</title>
      <description>&lt;p&gt;One of the things I love about programming is that you are always learning new things.  You &lt;em&gt;have&lt;/em&gt; to learn new things to keep up.&lt;/p&gt;

&lt;p&gt;One of the benefits of using the Plotr Javascript library for the language popularity stats I did is that instead of having to download separate images for each statistic, a user just fetches the library once and then a few small bits of data for each chart, which is probably a net savings, especially when I start to add more statistics.  However, Plotr, plus its various supporting libraries, is fairly hefty, so I needed to find a way to compress it.  One of the helpful people on the freenode IRC network's #javascript channel pointed me at Yahoo's &lt;a href="http://developer.yahoo.com/yui/compressor/"&gt;YUI Compressor&lt;/a&gt;, which is a nicely done project that squeezes quite a bit out of Javascript files.  I would recommend it to anyone else who needs to pare down their production JS files to the bare minimum.  Best of all, it's available under a very liberal open source license!&lt;/p&gt;

&lt;p&gt;Incidentally, over the course of the language stats project, I was surprised at how much helpful stuff Yahoo provides, first and foremost, a real &lt;a href="http://developer.yahoo.com/search/"&gt;API for their search engine&lt;/a&gt;, something that Google no longer has.  Hopefully, it's a sign of better things to come for them (if for no other reason than to keep Google on their toes!).&lt;/p&gt;

&lt;p&gt;By the way, for those interested in the language stats project, I set up a &lt;a href="http://forum.langpop.com/forums/1"&gt;forum&lt;/a&gt; with RSS feeds, where I will be posting updates, and accepting suggestions for further improvements.&lt;/p&gt;</description>
      <pubDate>Wed, 07 Nov 2007 11:29:00 -0800</pubDate>
      <guid isPermaLink="false">urn:uuid:37220b7f-6c45-4bdc-95ed-cb30f4668350</guid>
      <author>David N. Welton</author>
      <link>http://journal.dedasys.com/articles/2007/11/07/yui-compressor</link>
      <category>javascript</category>
      <trackback:ping>http://journal.dedasys.com/articles/trackback/1819</trackback:ping>
    </item>
    <item>
      <title>Chartr - Plotr generation for Rails</title>
      <description>&lt;p&gt;I've been working on a &lt;a href="http://www.langpop.com"&gt;project&lt;/a&gt; that uses graphics created with &lt;a href="http://solutoire.com/plotr/"&gt;Plotr&lt;/a&gt;, and I wanted to automate that from Rails, so I created &lt;a href="http://chartr.rubyforge.org/"&gt;Chartr&lt;/a&gt;.  It's not very complete, but works well enough to create stuff like this:&lt;/p&gt;

&lt;hr/&gt;

&lt;p&gt;&lt;script src="http://chartr.rubyforge.org/prototype1_5_1_1.js" type="text/javascript"&gt;&lt;/script&gt;
    &lt;script src="http://chartr.rubyforge.org/excanvas.js" type="text/javascript"&gt;&lt;/script&gt;
    &lt;script src="http://chartr.rubyforge.org/plotr_uncompressed.js" type="text/javascript"&gt;&lt;/script&gt;&lt;/p&gt;

&lt;p&gt;&lt;div class="chart"&gt;
      &lt;canvas id="results_chart" height="300" width="500"&gt;&lt;/canvas&gt;
    &lt;/div&gt;&lt;/p&gt;

&lt;script type="text/javascript"&gt;
var dataset = {"Number/Decade": [[0, 1000], [1, 5000], [2, 20000], [3, 22000]]};
var options = {colorScheme: "#22aa22", legend: {position: {}}, axis: {x: {ticks: [{label: "1960", v: 0}, {label: "1970", v: 1}, {label: "1980", v: 2}, {label: "1990", v: 3}]}}, padding: {left: 100}, background: {}, stroke: {}, legend: {position: {left: '120px'}}};
var discvar = new Plotr.BarChart("results_chart", options);
discvar.addDataset(dataset);
discvar.render();
&lt;/script&gt;

&lt;hr/&gt;

&lt;p&gt;Help is more than welcome!  I think the API is still a bit clumsy, more chart types need adding, and there are other things that could probably be improved, but it does work.&lt;/p&gt;</description>
      <pubDate>Tue, 30 Oct 2007 08:15:00 -0700</pubDate>
      <guid isPermaLink="false">urn:uuid:ff569c5f-e2ef-48ff-b50a-899b8fb4650f</guid>
      <author>David N. Welton</author>
      <link>http://journal.dedasys.com/articles/2007/10/30/chartr-plotr-generation-for-rails</link>
      <category>ruby</category>
      <category>rails</category>
      <category>javascript</category>
      <trackback:ping>http://journal.dedasys.com/articles/trackback/1816</trackback:ping>
    </item>
  </channel>
</rss>
