Extract JS former UI creation.