Laravel Count Array Length Javascript