Hi Michael,

Yes, I understand.. But I was wondering if the inject + destroy route
is the smartest way. like with vanilla js has the replaceChild
function...

On May 22, 4:18 pm, Michael Russell <[email protected]> wrote:
> You could implement your own `replaces` function within 
> Elements.http://jsfiddle.net/subhaze/AfeBV/
>
> Elements.implement('replaces', function(old, where){
>     if(!old) return;
>     var _where = where || 'after',
>         _old = document.id(old);
>     this.inject(_old, _where);
>     _old.destroy();
>
> });
>
> $$(elements).replaces(element);

Reply via email to