» Birthday Bundle - Over $400 worth of Envato files for just $20

jQuery Concrete: Support for ConcreteUI programming

Posted on November 2, 2009, Filled under jQuery,  Bookmark it

jquery.concrete

Hamish Friedlander’s JQuery Concrete tries to provide a new model of code organization. It intends to be a replacement for Object Oriented Programming that is focused on adding functions to groups of DOM elements based on the content and structure of those DOM elements. This merging of the model and view layer may seem weird initially, it can give very powerful results.

Basic Usage Example

Given this DOM example:

<body>
    <div class="internal_text">Internal text</div>
    <div class="attribute_text" rel="Attribute text"></div>
    <div>some text</div>
  </body>

And this concrete function:

  $('.internal_text').concrete({
    foo: function(){ console.log(this.text()); }
  });
  $('.attribute_text').concrete({
    foo: function(){ console.log(this.attr('rel')); }
  });

Then the following call:

$('div').foo();

The following result will be logged to the console:

Internal text
Attribute text 

We’re standing on the shoulders of giants here – combining ideas from Prototype’s behaviour & lowpro and jQuery’s effen & livequery (who themselves stole ideals from Self’s Morphic UI and others), but extending & combining the concepts presented in those tools to provide a complete alternative to traditional OO concepts – self-aware methods, inheritance, polymorphisim and namespacing without a single class definition.

Do you wish to receive the latest updates as soon as they are posted? Get our RSS Feed or Subscribe to the Newsletter!

Get our RSS Feed!

One Reply to "jQuery Concrete: Support for ConcreteUI programming"

  1. [...] the original post: JQuery Concrete: Support for ConcreteUI programming SHARETHIS.addEntry({ title: "JQuery Concrete: Support for ConcreteUI programming", url: [...]

Leave a Reply


* = required fields

  (will not be published)


XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Note: If you want to post CODE Snippets, please make them postable first!
(e.g. <br /> should be converted to &lt;br /&gt;)