Add JS docs.

not sure if that’s the best way. thoughts?