beasting a javascript