I'm doing work with JavaScript software transformation (JavaScript
source code in, different JavaScript source code out) using JavaScript
to implement the software transformation process :)

If it is possible to trap and modify JavaScript code before it is
parsed by the web browser, it would be extremely trivial to give
advisory names (naming a function expression, for instance) to all
functions.

In a product I am working on now, I end up writing out long advisory
names to every function, and if I get it wrong, or overlook a needed
change when using existing code as a template for new code, then it
can become very misleading.

So, is it possible or nearly possibly to trap and modify JavaScript
code before the browser parses it?

On Apr 28, 4:00 pm, John J Barton <[email protected]> wrote:
> On Apr 28, 9:37 am, Rob Campbell <[email protected]> wrote:
>
> > how many of the surveyed anonymous functions implemented a displayName
> > property on them?
>
> As far as I am able to figure out, one library  Cappicino and one
> cross compiler OpenLaszlo  use displayName.   We did not happen to use
> those in our study. More information is available 
> onhttp://code.google.com/p/fbug/issues/detail?id=1811.
>
> The displayName approach is fine for some users who use those
> libraries or who wish to invest time in naming functions but for some
> reason don't want to use names in function declarations. Salman's work
> allows development tools to support every user in some way without
> extra work on their part.
>
> jjb

-- 
You received this message because you are subscribed to the Google Groups 
"Firebug" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/firebug?hl=en.

Reply via email to