Offline
Online
Viewers
I'm Live!
Watch Now

Tag: javascript

Drawing on Textures in ThreeJS

If you’re an avid user of ThreeJS you have more than likely at some point run into the situation where you need to either create a texture from scratch for the point of coloring it, or have had the need to update/draw on a texture for one reason or another.  The following will walk you […]

Read More
New Rubik’s Cube jQuery Plugin

I consider myself an avid speed cuber. Not world class, but fast enough and not too obsessed with it. That being said all the sites I’ve seen in the past with references to algorithms all seem to use really clunky client side Java or Flash plugins to handle the demonstration of moves.  I wanted to […]

Read More
D3 and jQuery Interoperability

D3 and jQuery utilize distinctly different approaches to node manipulation and internal array storage. However, there are mechanisms available for converting between D3 and jQuery, and vice versa. D3 and jQuery Internals Let’s assume the following HTML structure: [codesyntax lang=”html4strict”] <div class=”test-node”>Test One</div> <div class=”test-node”>Test Two</div> <div class=”test-node”>Test Three</div> <div class=”test-node”>Test Four</div> [/codesyntax] Now let’s […]

Read More
Create jQuery Plugins: The Easy Way

If you’re a solid user of jQuery or just a tinkerer you may have thought to yourself “I have a great idea for a jQuery plugin”.  Your next steps of course would probably be to look at the jQuery documentation and eventually to have a look at someone else’s jQuery plugin source code.  In doing […]

Read More
Understanding JavaScript Promises In jQuery

You may or may not have heard the new buzz about promises being introduced into JavaScript and if you don’t know what they are, you’re not alone.  I’ll attempt to explain what they are and why you should or maybe shouldn’t care about them.  First let’s understand what promises are. Promise defined: “The Promise interface represents a […]

Read More
D3 Drag And Drop

Implementing drag and drop in D3 (http://d3js.org/) is a pretty simple task when you know how to do it, the following is a walkthrough from setup to execution and the events along the way. First thing we are going to want to do is setup our drag behavior.  This is the object that will be […]

Read More
Web Developer Essential Tools

Foreword The following highlights what I believe to be the best tools for web development and best of all, they’re all free.  This is a living reference which will be updated as new and better tools are found.  Feedback and suggestions are always welcome. The List Google Chrome Light, extremely fast, jam packed with features […]

Read More
Advanced JavaScript Notation

Forword The following javascript examples and notation demonstrate a few alternatives to well known methods for common tasks. Advanced Notation Tilde Operator The tilde operator “~” literally equates to “-(n+1)”.  For example: [codesyntax lang=”javascript”] var a = ~1; //returns -2 var myString = “hello world”; ~myString.indexOf(“hello”); //returns true [/codesyntax] Large Denary Numbers Large denary numbers […]

Read More
jQuery Quick Start Tutorial

Foreword The following is a quick crash course in using jQuery.  If you’ve never used jQuery before and want to know to how without reading a ton, this is the tutorial for you. Getting Started First download the latest version and include it in a page.  Grab the minified version for speed or if you […]

Read More
JavaScript Command Pattern

For this example of a Command pattern, we will create a simple “Interpreter” object and a basic “Command” object and demonstrate their respective use. Let’s first start with the “Interpreter”: [codesyntax lang=”javascript”] var Interpreter = {  execute: function(command){ //split on the space var commandArray = command.split(” “); try{ //use first entry as command name var […]

Read More
1 2

Affiliates