Web sites and web browsers have recently evolved into platforms
on top of which entire applications are delivered dynamically,
has sparked extremely enthusiastic efforts to customize
both individual web sites and entire browsers in ways the
original authors never expected or accommodated. Such customizations
take the form of yet more script dynamically
injected into the application, and the current idioms to do so
In this work, we accept the popularity of extensions and seek
better linguistic mechanisms to support them.
that allow straightforward and declarative ways for customization
code to modify the targeted application. Compared to
most prior aspect-related research, our work has a different
motivation and a different target programming environment,
both of which lead to novel design and implementation techniques.
Our aspect weaving is entirely integrated into a new
dynamic JIT compiler, which lets us properly handle advice
to first-class functions in the presence of arbitrary aliasing,
without resorting to whole-program code transformations.
Our prototype demonstrates that an aspect-oriented approach
to web-application customization is often more efficient than
current idioms while simplifying the entire process.