Programming

A JavaScript resizeDone Event for jQuery

Posted on

If you have ever handled a resize event in JavaScript, you will have noticed that when a user manually resizes their browser window by dragging the edges… you get a lot of events. This is because the resize event fires constantly as the user resizes the window. $window.on(‘resize’, function () { // Your code gets […]

Process

Hide Trello Columns

Posted on

If you have seen the average Trello board that has evolved over any length of time, you will have noticed they can suffer a little from column explosion. Fear not. You can use this short script to get rid of the boring columns with a single click. All you need to do is adjust the […]

Programming

The Novice View of Jquery

Posted on

I’m not picking on jQuery in particular here. I chose it because it is no doubt the biggest and most widely used example of a JavaScript library. So when I mention jQuery here, be in no doubt that this applies to Prototype, Mootools, and any other framework that makes your JavaScript easier to write. And […]

Programming

Using RequireJS and Jquery in TypeScript

Posted on

A common question I have come across on various TypeScript communities is how to use RequireJS to load jQuery. Of course, you could substitute “jQuery” here for pretty much anything. Here is a simple example to explain the concept, which you can use to load pretty much anything you like using require.js. Downloads You’ll need […]

Programming

Optimising Your jQuery

Posted on

jQuery is taking the JavaScript world by storm, but because it makes life so easy, it also makes it easy to forget about the amount of work you are asking the browser to do. This is especially important if you are performing an action against multiple elements, in a loop or as part of an […]

Programming

jQuery Get Text While Excluding Children

Posted on

I recently came across a problem while obtaining the text from an HTML label element, based on the fact that I knew the form element that related to the label. This came about because there are two valid ways to use a label. The first way is to use the “for” attribute on the label […]