Mildly Useful jQuery Plugins

Posted:   |  More posts about JavaScript jQuery Open Source

Over the last few years I have written some mildly useful jQuery plugins. I've had them published on BitBucket but I've never really announced them. Here they are.


After deciding to clean up a few rough edges on my site I noticed that BucketBadge, the jQuery plugin I wrote to display Badge - which is a summary of your Bitbucket profile - was no-longer showing the followers along with having a CSS line-height problem. It turns out that even though BitBucket had versioned their API and still have the followers_count attribute in their documentation they have clearly deprecated it. To get the same information now I have to make extra API call and I had to rewrite a large part of the plugin code. When Atlassian/Bitbucket deprecate the 1.0 API I will have to re-write for their 2.0 API. Integrating the badges is extremely easy as they are CSS themeable and have only a few configuration parameters.


A list of my repos on the left, and a mid-transition badge from @jespern on the right.

You can see this plugin in action at this demo page and on my main page.


I wrote dForm-generate while working on a web application to do quizzes. The idea was that I would create a form builder in JavaScript and then use this plugin to serialize it into JSON for storage in the database. The form would be deserialsed and built by the jquery.dform plugin. The quiz project eventually stalled and never went ahead. It's not complete or well tested but it definitely seems to mostly work.


A shoddy drag and drop form builder prototype using dform-generate.

You can have a quick play with it on the demo page #1 and the most basic useage on demo page #2.


Another nice piece of code I wrote during the quiz project was this small jQuery plugin that injects HTML into the DOM given a URL to a source document. jQuery can do this in a single line of code, but the interesting part is when you want to inject a particular part of the source document. jquery.loadFrag enables you to specify a selector to specify the section of the source file to inject. If you have many fragments you want to pull in then your server should only get hit for the HTML file once as it should be cached on the local user's machine or proxy. It also has a handy side-effect of being able to execute JavaScript embedded in the HTML snippets. Do away kludge of files with HTML snippets by effectively creating a sprite sheet for HTML!


jquery.Loadfrag loading snippets from another HTML file and also executing the embedded JavaScript.

You can see it in action at this demo page.

So there's the mildly useful jQuery plugins I've written. They're all MIT licensed. I have more interesting snippets of code in my BitBucket repository and maybe I will make a post to point them out sometime

Comments powered by Disqus
Contents © 2015 Daniel Devine - Nikola Powered - Flattr Me! Flattr this Source