User blog comment:LadyAlys/HabitRPG Unofficial User Data Display/@comment-24185151-20140331143628/@comment-24150802-20140401000551

Your comment made me smile a lot!

I labelled it unofficial so it would be clear that the HabitRPG staff aren't responsible for any bugs there might be in it, and so that I could do whatever I felt like with it without worrying too much about how anyone else would feel. :) So I haven't put any thought into what would be required to make it "official". I'm really just playing around at the moment to see what's possible, and frankly I'm a little surprised at how well it seems to be working out.

It's written in JavaScript with jQuery (a JavaScript library that makes using JavaScript much easier). Before this, I hadn't done much with either of those, so this is a learning experience for me (another reason it's good to not be official: it doesn't matter that some parts of my code could probably benefit from improvement!) I haven't taken classes in those technologies; I just read material on the internet whenever I need to learn something new.

I haven't kept track of how long it's taken me. Maybe I should - but then it might feel too much like work! Most of it has actually been quite easy, but the Tasks Overview took three of four more times longer than I expected! I started out by using a particular library for creating sortable and filterable tables, and put a fair bit of work into it then realised it had some limitations I didn't like, so I tried another library, and ended up not liking that either. Then I tried a third one, then went back to the first one, then realised the first one still annoyed me, so I tried another four or five, with ever-decreasing amounts of time spent on each, and then I punched the computer a few times and went back to the first one. :) That's the one that I list on the page (Data Tables) and it's actually really good - I found that it has other features that get around my original problem with it. I'm impressed by how much flexibility it gives me! You can do REALLY cool things like for a single column (e.g., value/colour) you can specify one piece of text that's displayed on the page (value and colour together), and a different piece of text that's used for sorting (value alone, so it sorts numerically), and a different piece that's used for filtering (colour alone, so you get that cute little drop-down colour filter list). Awesome!

The real magic comes from the data source. HabitRPG stores all of a user's data in a single, large "file" (actually JSON data) that you can download using the excellent API. The data is structured VERY neatly - organised into a tree-like structure that lets you easily pull out what you want. I'm deeply impressed with and grateful to Tyler for making HabitRPG open-source and for making the data and API available in such a useful fashion.

I'm having a lot of fun building this tool. I just wish I had more time to spend on it. :( There's this damn company in town that expects me to do work for them for seven or eight hours every weekday! So rude. :)