add JS for favorite-ing