Moved wrapping to host JavaScript.