cap And js modification