Replace fugu with js version