dynamic chat update with js