I managed to put the pendulum demo on the front main page along with the creatures demo.  It was a bit of a nightmare.  There were loads of conflicts between various javascript libs and the solution was to carefully split everything up into self contained neat modules.  In addition, since p5.js takes away all touch functionality from smart phones, that part of the code had to be cleverly hidden away if a mobile device got detected.