[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: better (?) than DOM

  • From: Robin Berjon <robin@j...>
  • To: Nathan Young -X ((natyoung - Artizen at Cisco)) <natyoung@c...>
  • Date: Fri, 23 Feb 2007 12:51:19 +0100

Re:  better (?) than DOM
On Feb 22, 2007, at 18:45, Nathan Young -X ((natyoung - Artizen at  
Cisco)) wrote:
> I'll repost with a little explanation because I'm curious if anyone  
> has seen something like this.  Absent XML4J it's not completely  
> crazy to create violent shortcuts for creating nodes  
> programmatically.  Although it is chained method calls, it comes  
> remarkably close to looking like a markup language:
>
> jQuery('#myDiv').append(
>     jQuery.DIV({'class':'big'},
>         jQuery.SPAN({id:'one','class':'ps'},
>             'Hello Joe', jQuery.I({},'!')
>         )
>     )
> );

Maybe it's just me but even though I've been doing Javascript quite a  
fair bit and for a long time, I don't find the above particularly  
attractive. It seems to be begging for E4X, which is IMHO a lot  
clearer than the above.

--
Robin Berjon
........................................................................
"Let us think the unthinkable, let us do the undoable. Let us prepare
  to grapple with the ineffable itself, and see if we may not eff it
  after all."
             -- Dirk Gently (Douglas Adams)




[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]


PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.