update example with fixed js