Older blog entries for sness (starting at number 5056)

Organizing your application using Modules (require.js) - Backbone.js Tutorials

Organizing your application using Modules (require.js) - Backbone.js Tutorials: "Our applications main module should always remain light weight. This tutorial only covers setting up a Backbone Router and initializing it in our main module.

The router will then load the correct dependencies depending on the current URL.

"

'via Blog this'

Syndicated 2013-02-01 07:44:00 from sness

Building a basic drum sound trigger machine – Part 1. | Interactive Audio: Learn how to build web & mobile audio applications using Javascript & the Web Audio API.

Building a basic drum sound trigger machine – Part 1. | Interactive Audio: Learn how to build web & mobile audio applications using Javascript & the Web Audio API.:

'via Blog this'

Syndicated 2013-02-01 07:31:00 from sness

Build Backbone Apps Using RequireJS | Simple Thoughts

Build Backbone Apps Using RequireJS | Simple Thoughts: "Since coding is by far easier than explaining, I programmed a Todos app in order to demonstrate how this can be done with Asynchronous Module Definition (AMD) using RequireJS."

'via Blog this'

Syndicated 2013-02-01 06:29:00 from sness

javascript - Loading jQuery, Underscore and Backbone using RequireJS 2.0.1 and shim - Stack Overflow

javascript - Loading jQuery, Underscore and Backbone using RequireJS 2.0.1 and shim - Stack Overflow: "You only need to use "shim" config if the library does not already call define() to declare a module. jquery does this already, so you can remove that from the shim config. The above code will work as is, but the exports shim config for jquery will be ignored since jquery will call define() before the shim work is done."

'via Blog this'

Syndicated 2013-02-01 06:28:00 from sness

twitter/flight · GitHub

twitter/flight · GitHub: "How do I apply mixins to a regular object?

Under the covers, Components add mixins using Flight's compose module, which amongst other things, prevents mixins from clobbering existing method names. If you ever need to apply a mixin to something other than a component (e.g. to another mixin), you can invoke compose.mixin directly:"

'via Blog this'

Syndicated 2013-02-01 00:53:00 from sness

Flight by Twitter

Flight by Twitter: "Mixins

A mixin defines a set of functionality that is useful to more than one object. Flight comes with built-in support for functional mixins, including protection against unintentional overrides and duplicate mixins. While classical JavaScript patterns support only single inheritance, a component (or other object) can have multiple mixins applied to it. Moreover mixins requires a fraction of the boilerplate required to form traditional classical hierarchies out of constructor-prototypes hybrids, and don't suffer the leaky abstractions of the latter ('super', 'static', 'const' etc.)

"

'via Blog this'

Syndicated 2013-02-01 00:46:00 from sness

Adequately Good - JavaScript Module Pattern: In-Depth - by Ben Cherry

Adequately Good - JavaScript Module Pattern: In-Depth - by Ben Cherry: "Anonymous Closures

This is the fundamental construct that makes it all possible, and really is the single best feature of JavaScript. We'll simply create an anonymous function, and execute it immediately. All of the code that runs inside the function lives in a closure, which provides privacy and state throughout the lifetime of our application.

(function () {
// ... all vars and functions are in this scope only
// still maintains access to all globals
}());
Notice the () around the anonymous function. This is required by the language, since statements that begin with the token function are always considered to be function declarations. Including () creates a function expression instead.

"

'via Blog this'

Syndicated 2013-01-31 22:29:00 from sness

Adequately Good - JavaScript Module Pattern: In-Depth - by Ben Cherry

Adequately Good - JavaScript Module Pattern: In-Depth - by Ben Cherry: "The module pattern is a common JavaScript coding pattern. It's generally well understood, but there are a number of advanced uses that have not gotten a lot of attention. In this article, I'll review the basics and cover some truly remarkable advanced topics, including one which I think is original."

'via Blog this'

Syndicated 2013-01-31 22:28:00 from sness

5047 older entries...

New Advogato Features

New HTML Parser: The long-awaited libxml2 based HTML parser code is live. It needs further work but already handles most markup better than the original parser.

Keep up with the latest Advogato features by reading the Advogato status blog.

If you're a C programmer with some spare time, take a look at the mod_virgule project page and help us with one of the tasks on the ToDo list!