js count changes