oops!
add lame impls for js
fix test