Try it live: https://martinrenou.github.io/threejs-water
This is an implementation of Evan Wallace's webgl-water demo using ThreeJS.
You can find another implementation of the caustics computation here: https://github.com/martinRenou/threejs-caustics This other implementation supports any kind of mesh in the pool.