Leveraging Legacy Code for Web Browsers