add client side logic