Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Experimental async library inspired by ControlJS
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  6 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
cdata  
View profile  
 More options Apr 8 2011, 3:11 pm
From: cdata <aar...@gmail.com>
Date: Fri, 8 Apr 2011 12:11:05 -0700 (PDT)
Local: Fri, Apr 8 2011 3:11 pm
Subject: Experimental async library inspired by ControlJS
Hello Steve and everyone else,

I've been closely following ControlJS from its creation. I really like
the approach that it takes to async loading, but after doing a lot of
testing I found that the document.write wrapping was kind of a crap
shoot (especially when it comes to pesky little things like
advertisements).

I have started development on a library that takes the same approach
to enabling asynchronous pre-caching and synchronous execution of
scripts as ControlJS (in fact, it started as a fork), while also being
almost 100% document.write compatible.

The library attempts to buffer document.write calls and parse them as
closely to the way that a browser parses the original document as
possible, creating and inserting all new nodes using post-load-safe
DOM tree insertion methods. Using this technique, the library can
correctly load many obscure scenarios that the span + innerHTML
technique doesn't accomodate well for.

The library is currently being tracked on GitHub: https://github.com/cdata/dominatejs

It's kind of a behemoth right now, but I'm working on slimming it
down. Anyway, I wanted to put the word out there about this, and I'd
love to get some feedback from any of you on what you think and / or
how it could be improved!

Chris


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
noah  
View profile  
 More options Apr 8 2011, 3:41 pm
From: noah <iamn...@gmail.com>
Date: Fri, 8 Apr 2011 14:41:20 -0500
Local: Fri, Apr 8 2011 3:41 pm
Subject: Re: Experimental async library inspired by ControlJS
Hi!

I've also got a document.write lib:
https://github.com/iamnoah/writeCapture that integrates with CJS:
https://github.com/iamnoah/writeCapture/wiki/ControlJS

I haven't tried it out, but it looks like you're trying to parse input
as it arrives and create DOM nodes immediately, right? Sounds very
cool, I hope you can make it work. My lib waits for completion for the
most part, but there is a class of script (that use DOM and
document.write for some reason) that is tough to work with. Your
approach looks promising. Have you looked at John Resig's HTML parser?
http://ejohn.org/blog/pure-javascript-html-parser/

That might be able to cut down your code size a bit.

Cheers,
Noah


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Steve Souders  
View profile  
 More options Apr 8 2011, 3:53 pm
From: Steve Souders <st...@souders.org>
Date: Fri, 08 Apr 2011 12:53:34 -0700
Local: Fri, Apr 8 2011 3:53 pm
Subject: Re: Experimental async library inspired by ControlJS
It's great to see these projects. I think parsing & applying the
document.write DOM in real time is key.

-Steve

On 4/8/2011 12:41 PM, noah wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Dave Artz  
View profile  
 More options Apr 8 2011, 4:06 pm
From: Dave Artz <davea...@gmail.com>
Date: Fri, 8 Apr 2011 16:06:29 -0400
Local: Fri, Apr 8 2011 4:06 pm
Subject: Re: Experimental async library inspired by ControlJS

Steve, whatever happened to the <frag> tag? :)

Seems like a lot of bulk to work around document.write, how are browser
manufacturers reacting to this problem?


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Steve Souders  
View profile  
 More options Apr 8 2011, 4:11 pm
From: Steve Souders <st...@souders.org>
Date: Fri, 08 Apr 2011 13:11:19 -0700
Local: Fri, Apr 8 2011 4:11 pm
Subject: Re: Experimental async library inspired by ControlJS

I still like the FRAG tag idea. One of the arguments against it is that
HTML5 iframes can do much the same thing. And we've seen Google AdSense
use iframes to get asynchronous document.write to work. More work and
not perfect, but it is possible.

-Steve

On 4/8/2011 1:06 PM, Dave Artz wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
cdata  
View profile  
 More options Apr 8 2011, 8:36 pm
From: cdata <aar...@gmail.com>
Date: Fri, 8 Apr 2011 17:36:05 -0700 (PDT)
Local: Fri, Apr 8 2011 8:36 pm
Subject: Re: Experimental async library inspired by ControlJS
Actually, the parser we're using _was_ inspired by John Resig's
parser, but is not the same. The project for it is located here:
https://github.com/jtwb/node-htmlparser

Sadly our solution doesn't share the same compact size that
writeCapture has, so that's probably one of the first places for us to
start optimizing.

In general, there seem to be a lot of really tricksy document.write
scenarios out there. We've tried to start building tests for them
(available in the Domiante repo), and would definitely welcome
contributions!

Chris

On Apr 8, 1:11 pm, Steve Souders <st...@souders.org> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »