added javascript binding