Make JavaScript audio samples able to be looped

Add a "loop" property to AudioInjectorOptions and provide an example JavaScript file.
Merge pull request #2954 from ctrlaltdavid/19715

Code Review for Job #19715